摘要:
The problem of this solution can be BFS and DFS. BFS is easy to understand. The following is DFS solution: private List<Integer> res = new ArrayList<> 阅读全文
摘要:
The first solution, the easiest one, time complexity: O(nlog(n)) public int findKthLargest(int[] nums, int k) { Arrays.sort(nums); if(k<=nums.length) 阅读全文
摘要:
For this problem, we must know the sign just before the num. For example, s = "3+2*2", when we deal with the first 2, we must know '+' is just before 阅读全文