All test case not working

hello @souravkhanna227
image

size array is reduandant . u r storing the same information in map so use map only.

still not working 2 testcases

a) use unordered_map

b) if there exist more than 1 element with highest frequency then print minimum among them
check ur updated code->https://ide.codingblocks.com/s/281783

sir why we have used unordered map if we use ordered map then it itself would return a minimun element

but it take log(n) time .
whereas unordered take o(1) time on average