You are given a usageLimits.
There are usageLimits.length distinct elements labeled from usageLimits.length i at most usageLimits[i] times in total across all created groups.
Your goal is to form the maximum number of groups such that:
Each group contains only distinct elements.
Each group has a size strictly greater than the size of the previous group.
Return the maximum number of groups that can be constructed under these conditions.
Constraints:
usageLimits.length
usageLimits[i]
You are given a usageLimits.
There are usageLimits.length distinct elements labeled from usageLimits.length i at most usageLimits[i] times in total across all created groups.
Your goal is to form the maximum number of groups such that:
Each group contains only distinct elements.
Each group has a size strictly greater than the size of the previous group.
Return the maximum number of groups that can be constructed under these conditions.
Constraints:
usageLimits.length
usageLimits[i]