摘要: #include <vector> #include <iostream> #include <cassert> #include <queue> #include <algorithm> using namespace std; //找到l-r里的一个随机元素,并和nums[r]替换 //返回大于 阅读全文
posted @ 2021-12-17 16:02 hh13579 阅读(23) 评论(0) 推荐(0) 编辑
摘要: /* * @lc app=leetcode.cn id=215 lang=cpp * * [215] 数组中的第K个最大元素 */ // @lc code=start class Solution { public: int findKthLargest(vector<int>& nums, int 阅读全文
posted @ 2021-12-17 15:41 hh13579 阅读(19) 评论(0) 推荐(0) 编辑