2017年11月27日

最小的k个数

摘要: 题目描述 输入n个整数,找出其中最小的K个数。例如输入4,5,1,6,2,7,3,8这8个数字,则最小的4个数字是1,2,3,4,。 法一:排序 1 class Solution { 2 public: 3 vector<int> GetLeastNumbers_Solution(vector<in 阅读全文

posted @ 2017-11-27 15:26 wsw_seu 阅读(123) 评论(0) 推荐(0) 编辑

导航