Sponsored
Sponsored
Use these hints if you're stuck. Try solving on your own first.
Note that you can try all values in a brute force manner and find the maximum frequency of that value.
To find the maximum frequency of a value consider the biggest elements smaller than or equal to this value