摘要:
Leetcode150 逆波兰表达式求值 题目链接 栈 class Solution { public int evalRPN(String[] tokens) { Deque<Integer> stack = new LinkedList(); for (String s : tokens) { 阅读全文
摘要:
Leetcode344 反转字符串 题目链接 双指针思想 交换字符即可 class Solution { public void reverseString(char[] s) { int l = 0; int r = s.length-1; while(l<r){ char tep = s[l]; 阅读全文