码迷,mamicode.com
首页 >  
搜索关键字:same-tree    ( 180个结果
Same Tree 深度优先
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 identical an...
分类:其他好文   时间:2014-11-19 20:18:28    阅读次数:143
两道关于binary tree的水题 [Same Tree] [Maximum Depth of Binary Tree]
Same TreeGiven two binary trees, write a function to check if they are equal or not.Two binary trees are considered equal if they are structurally ide...
分类:其他好文   时间:2014-11-15 11:13:11    阅读次数:171
Same Tree (二叉树DFS)
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 identical an...
分类:其他好文   时间:2014-11-06 19:07:13    阅读次数:205
[leetcode]Same Tree
问题描述: 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 identical and the nodes have the same value. ...
分类:其他好文   时间:2014-10-27 21:17:54    阅读次数:165
Same Tree 判断相同树
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 identical an...
分类:其他好文   时间:2014-10-27 08:09:30    阅读次数:167
【LeetCode】Same Tree
题目: 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 identical and the nodes have the same value....
分类:其他好文   时间:2014-10-25 23:09:06    阅读次数:447
LeetCode:Same Tree
问题描述: 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 identical and the nodes have the same value. 解...
分类:其他好文   时间:2014-10-24 13:03:03    阅读次数:148
Same Tree 比较两个二叉树是否完全相同
Given two binarytrees, write a function to check if they are equal or not.Two binary trees are considered equal if they are structurally identical and...
分类:其他好文   时间:2014-10-21 23:02:04    阅读次数:240
leetcode:Same Tree【Python版】
1、p或q为None的情况用开始的两个if语句进行判断;2、类中递归调用函数需要使用self进行调用;3、代码很简洁,最后几行通过同时为None和同时非None的条件进行判断; 1 # Definition for a binary tree node 2 # class TreeNode: 3 ....
分类:编程语言   时间:2014-10-19 01:17:13    阅读次数:329
LeetCode——Same Tree(判断两棵树是否相同)
问题: 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 identic...
分类:其他好文   时间:2014-10-07 17:55:43    阅读次数:127
180条   上一页 1 ... 14 15 16 17 18 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!