码迷,mamicode.com
首页 >  
搜索关键字:二叉树.binary tree    ( 18099个结果
leetcode - Recover Binary Search Tree
题目:Recover Binary Search TreeTwo elements of a binary search tree (BST) are swapped by mistake.Recover the tree without changing its structure.Note:A ...
分类:其他好文   时间:2014-06-28 10:26:38    阅读次数:253
【Leetcode】Path Sum
Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum. For example: Given the below binary tree and sum...
分类:其他好文   时间:2014-06-22 20:59:24    阅读次数:227
LeetCode——Binary Tree Postorder Traversal
Given a binary tree, return the postorder traversal of its nodes' values. For example: Given binary tree {1,#,2,3}, 1 2 / 3 return [3,2,1]. Note: Recursive solut...
分类:其他好文   时间:2014-06-22 20:58:01    阅读次数:157
POJ2405-Beavergnaw
Beavergnaw Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 6204   Accepted: 4090 Description When chomping a tree the beaver cuts a very specific shape out o...
分类:其他好文   时间:2014-06-22 17:06:55    阅读次数:233
LeetCode——Binary Tree Preorder Traversal
Given a binary tree, return the preorder traversal of its nodes' values. For example: Given binary tree {1,#,2,3}, 1 2 / 3 return [1,2,3]. Note: Recursive soluti...
分类:其他好文   时间:2014-06-22 16:37:51    阅读次数:168
hust 1016 Black-White Tree
题目描述在图论中,包含n个结点(结点编号为1~n)、n-1条边的无向连通图被称为树。 在树中,任意一对结点间的简单路径总是惟一的。 你拥有一棵白色的树——所有节点都是白色的。接下来,你需要处理c条指令: 修改指令(0 v):改变一个给定结点的颜色(白变黑,黑变白); 查询指令(1 v):询问从结点1...
分类:其他好文   时间:2014-06-22 12:55:54    阅读次数:213
Vim 中文件目录浏览插件——NERD tree
说明 :vim的插件NERDTree用于使得vim窗口分左右窗口显示的用法说明。其中,左侧为目录的树形界面,简称为NERDTree界面,右则为vim界面。 一、配置步骤 下载地址: http://www.vim.org/scripts/script.php?script_id=1658 或者 htt...
分类:其他好文   时间:2014-06-22 11:53:04    阅读次数:258
Leetcode-Sum Root to Leaf Numbers
题目: Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent a number. An example is the root-to-leaf path 1->2->3 which represents the number 123. Find...
分类:其他好文   时间:2014-06-22 08:30:24    阅读次数:236
leetcode__Convert Sorted List to Binary Search Tree
Convert Sorted List to Binary Search Tree  Total Accepted: 12283 Total Submissions: 45910My Submissions Given a singly linked list where elements are sorted in ascending order, convert it...
分类:其他好文   时间:2014-06-21 23:57:00    阅读次数:351
【Leetcode】Path Sum II
Given a binary tree and a sum, find all root-to-leaf paths where each path's sum equals the given sum. For example: Given the below binary tree and sum = 22, 5 / ...
分类:其他好文   时间:2014-06-21 22:44:58    阅读次数:266
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!