Breadth-first Search
文章平均质量分 81
candy_crush
胡编乱写
展开
-
Symmetric Tree
Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center).For example, this binary tree [1,2,2,3,4,4,3] is symmetric: 1 / \ 2 2 / \ / \3 4 4 3原创 2016-09-17 18:07:50 · 235 阅读 · 0 评论 -
Binary Tree Level Order Traversal I和II 层次遍历二叉树
Given a binary tree, return the level order traversal of its nodes' values. (ie, from left to right, level by level).For example:Given binary tree [3,9,20,null,null,15,7], 3 / \ 9 2原创 2016-09-17 21:13:19 · 306 阅读 · 0 评论