码迷,mamicode.com
首页 >  
搜索关键字:reverse nodes    ( 8673个结果
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 le...
分类:其他好文   时间:2014-09-16 00:15:49    阅读次数:196
LeetCode:Merge Two Sorted Lists
Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the first two lists.思路:增加一个头指...
分类:其他好文   时间:2014-09-15 22:38:49    阅读次数:217
LeetCode Clone Graph
Clone an undirected graph. Each node in the graph contains alabeland a list of itsneighbors.OJ's undirected graph serialization:Nodes are labeled uniq...
分类:其他好文   时间:2014-09-15 21:09:39    阅读次数:216
Leetcode: Binary Tree Level Order Transversal II
Given a binary tree, return the bottom-up level order traversal of its nodes' values. (ie, from left to right, level by level from leaf to root).For e...
分类:其他好文   时间:2014-09-15 14:13:38    阅读次数:153
Leetcode: Binary Tree Level Order Transversal
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,...
分类:其他好文   时间:2014-09-15 14:07:38    阅读次数:175
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-09-15 12:41:48    阅读次数:133
数组排序
一直都对数组排序有点混淆不清,今天闲下来硬是找了些资料好好补课一下,感觉如下这篇还不错,于是转过来了。 reverse()、sort() 和 sortOn() reverse() 倒序排列sort() 按照多种预定义的方式对数组进行排序,甚至可用来创建自定义排序算法。sortOn() 方法可用来对对...
分类:其他好文   时间:2014-09-15 12:35:08    阅读次数:155
Leetcode: Binary Tree Inorder Transversal
Given a binary tree, return the inorder traversal of its nodes' values.For example:Given binary tree {1,#,2,3}, 1 \ 2 / 3return [1,3,2]....
分类:其他好文   时间:2014-09-15 09:54:08    阅读次数:135
[leetcode]Swap Nodes in Pairs @ Python
原题地址:http://oj.leetcode.com/problems/swap-nodes-in-pairs/Given a linked list, swap every two adjacent nodes and return its head.For example,Given 1->2...
分类:编程语言   时间:2014-09-15 06:38:18    阅读次数:200
[Leetcode][JAVA] Merge Two Sorted Lists & Sort List
Merge Two Sorted Lists:Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the fi...
分类:编程语言   时间:2014-09-15 01:02:17    阅读次数:269
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!