码迷,mamicode.com
首页 >  
搜索关键字:nodes    ( 4030个结果
Binary Tree Level Order Traversal II 二叉树层序遍历之二
Given a binary tree, return thebottom-up level ordertraversal of its nodes' values. (ie, from left to right, level by level from leaf to root).For exa...
分类:其他好文   时间:2014-10-26 06:47:17    阅读次数:187
【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】 Maximum Depth of Binary Tree
题目 Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf node....
分类:其他好文   时间:2014-10-25 18:50:01    阅读次数:137
Partition List
Given a linked list and a valuex, partition it such that all nodes less thanxcome before nodes greater than or equal tox.You should preserve the origi...
分类:其他好文   时间:2014-10-25 15:47:52    阅读次数:225
Power Network (poj 1459 网络流)
Language: Default Power Network Time Limit: 2000MS   Memory Limit: 32768K Total Submissions: 23407   Accepted: 12267 Description A power network consists of nodes (po...
分类:Web程序   时间:2014-10-24 22:21:49    阅读次数:265
LeetCode:Maximum Depth of Binary Tree
题目描述: Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf node. 解题思路:直接DFS。 代码: /**...
分类:其他好文   时间:2014-10-24 13:04:21    阅读次数:147
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
[Leetcode][JAVA] Clone Graph, Copy List with Random Pointer
Clone Graph:Clone an undirected graph. Each node in the graph contains alabeland a list of itsneighbors.OJ's undirected graph serialization:Nodes are ...
分类:编程语言   时间:2014-10-24 09:07:12    阅读次数:227
Add Two Numbers
You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single ...
分类:其他好文   时间:2014-10-23 22:15:45    阅读次数:130
[Leetcode] Binary Tree Preorder Traversal
Given a binary tree, return thepreordertraversal of its nodes' values.For example:Given binary tree{1,#,2,3}, 1 \ 2 / 3return[1,2,3].Not...
分类:其他好文   时间:2014-10-22 14:32:39    阅读次数:131
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!