To find the two classes with the minimum and maximum number of players, initialize counters for each class and iterate through the list of player weights, incrementing the counter of their corresponding class. Finally, find the class with the minimum and maximum counter values.
To find the two classes with the maximum and minimum possible number of players, we can use a counting algorithm to keep track of the number of players in each class. We initialize counters for each class and iterate through the list of player weights. For each player, we increment the counter of their corresponding class. At the end, we find the class with the minimum and maximum counter values to determine the two classes with the minimum and maximum number of players.
Initialize counters for each class: A = 0, B = 0, C = 0, D = 0, F = 0.
Iterate through the list of player weights.
For each player, increment the corresponding class counter.
Find the class with the minimum counter value to determine the class with the minimum number of players.
Find the class with the maximum counter value to determine the class with the maximum number of players.
Return the classes and their respective number of players.