【leetcode】227(Medium)Basic Calculator II

解题思路 还是用栈 提交代码 class Solution { public int calculate(String s) { int res=0,p=0,num=0,tmp=0,flag=1; Stack<Integer> stack=new Stack<Integer>(); while(p<s.length()) { if(s.
相关文章
相关标签/搜索