![](https://img-blog.csdnimg.cn/20201014180756913.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
LeetCode解题笔记
jQueryZK
本科在校软件专业学生,正在奔向程序员的道路上
展开
-
LeetCode解题笔记-LC2-计算逆波兰式(后缀表达式)的值(Postfix expression evaluation)
题目描述: Calculate the value of inverse Polish (postfix expression) The operator only contains " +", “-”, “*” and “/”, the operand may be an integer or other expressions 计算逆波兰式(后缀表达式)的值运算符仅包含"+","-“和”/".被操作数可能是整数或其他表达式 例如: ["2", "1", "+", "3", "*"] -> ((2原创 2020-09-20 15:40:39 · 1990 阅读 · 0 评论 -
LeetCode解题笔记-LC1-二叉树最小深度(minimum-depth-of-binary-tree)
题目描述 Given a binary tree, find its minimum depth.The minimum depth is the number of nodes along the shortest path from the root node down to the nearest leaf node. 求给定二叉树的最小深度。(最小深度是指树的根结点到最近叶子结点的最短路径上结点的数量) 示例: 输入: {1,2,3,4,5} 输出:2 方法一:递归 运行时间: 41ms 占原创 2020-09-17 15:57:39 · 1731 阅读 · 0 评论