Approach hintTry it first, then revealHide
Only two numbers matter: how many distinct skills exist and the largest frequency of a single skill. Consider whether the most frequent skill should also give one student to the team of distinct skills.
Only two numbers matter: how many distinct skills exist and the largest frequency of a single skill. Consider whether the most frequent skill should also give one student to the team of distinct skills.