subarray是截取数组中连续的一段子数组。(substring同理) subsequence是序列中不连续的一段子序列。 [1,2,3,4,5,6] subarray=[3,4,5]; subsequence=[2,4,5];
priority_queue
LeeteCode 347.Top K Frequent Elements本题要注意的是语法上的东西: priority_queue 、pair class Solution {public: vector<int> topKFrequent(vector<int& ...
二叉树的遍历(C++实现)
定义二叉树结点类struct BinaryTreeNode { int val; BnaryTreeNode* lc; BinaryTreeNode* rc; BinaryTreeNode (int cont& _val, BinaryTreeNode* _ ...