摘要:
Quetion: Given two binary trees, write a function to check if they are equal or not. Two binary trees are considered equal if they are structurally id 阅读全文
摘要:
Question: Find the sum of all left leaves in a given binary tree. Example: 分析:题目很容易理解,求出树的所有左叶子节点的和,需要注意的是,必须是对左叶子节点求和,所以根节点,非叶子节点,右叶子节点都不符合条件 解法一:递归 阅读全文
摘要:
Question: Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements. For ex 阅读全文
摘要:
开始刷leetcode了,记录做过的题目以及做题过程思路的整理,还会贴出自己认为的别人写的好的代码,会不定期的更新~~~~ Question Content: Write a function that takes a string as input and returns the string r 阅读全文