You are given an integer n representing the total number of players indexed from n
You are also given a pick, where each pick[i] = [x_i, y_i] indicates that player x_i selected a ball of color y_i.
Player i wins the game if they collect strictly more than i balls of the same color (that is, at least i
Return the total count of players who win the game.
Note: Multiple players can win the game, and each winning player is counted only once.
Constraints:
n
pick.length
pick[i].length
n
You are given an integer n representing the total number of players indexed from n
You are also given a pick, where each pick[i] = [x_i, y_i] indicates that player x_i selected a ball of color y_i.
Player i wins the game if they collect strictly more than i balls of the same color (that is, at least i
Return the total count of players who win the game.
Note: Multiple players can win the game, and each winning player is counted only once.
Constraints:
n
pick.length
pick[i].length
n