Loading...
By continuing to use the platform, you accept the terms of the Privacy Policy and the use of cookies.
nums and an integer k,
and returns an array of the k most frequently occurring elements.
Conditions:
k is greater than the number of unique elements in the array, return all unique elements.Run your code to see results.
Click the Run button above
nums and an integer k,
and returns an array of the k most frequently occurring elements.
Conditions:
k is greater than the number of unique elements in the array, return all unique elements.