You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
funmaximizeGreatness(nums:IntArray): Int {
val n = nums.size
nums.sort()
var great =0for (i in0 until n) {
if (nums[great] < nums[i]) {
great++
}
}
return great
}