Meta Interview Question

They asked a leetcode Top K Frequent Elements