LeetCode 347. Top K Frequent Elements(最频繁的K个元素)
原题网址:https://leetcode.com/problems/top-k-frequent-elements/
Given a non-empty array of integers, return the k most frequent elements.
For example,
Given [1,1,1,2,2,3] and k = 2, return [1,2].
原创
2016-05-18 08:58:53 ·
995 阅读 ·
1 评论