An apparatus comprising a plurality of storage nodes comprising a plurality of corresponding storage disks and configured to store data in a distribut...
分类:
移动开发 时间:
2014-08-07 03:01:28
阅读次数:
456
Given a linked list, reverse the nodes of a linked listkat a time and return its modified list.If the number of nodes is not a multiple ofkthen left-o...
分类:
其他好文 时间:
2014-08-07 00:37:17
阅读次数:
187
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-08-07 00:15:17
阅读次数:
187
Another list manipulation problem.class Solution {public: ListNode *reverseKGroup(ListNode *head, int k) { if (!head) return head; if...
分类:
其他好文 时间:
2014-08-06 06:14:10
阅读次数:
232
Graph Coloring You are to write a program that tries to find an optimal coloring for a given graph. Colors are applied to the nodes of the graph and t...
分类:
其他好文 时间:
2014-08-05 13:31:49
阅读次数:
215
Evaluate Reverse Polish NotationEvaluate the value of an arithmetic expression inReverse Polish Notation.Valid operators are+,-,*,/. Each operand may ...
分类:
其他好文 时间:
2014-08-05 10:57:19
阅读次数:
184
String?str1?=?"123456789";
??str1?=?new?StringBuilder(str1).reverse().toString();?????//先将字符串颠倒顺序
??String?str2?=?"";
??for(int?i=0;i<str1.length();i++){
??...
分类:
编程语言 时间:
2014-08-05 09:44:49
阅读次数:
232
Given a binary tree, determine if it is a valid binary search tree (BST).
Assume a BST is defined as follows:
The left subtree of a node contains only nodes with keys less than the node's key.Th...
分类:
其他好文 时间:
2014-08-05 09:43:39
阅读次数:
191
题目: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....
分类:
编程语言 时间:
2014-08-05 05:18:28
阅读次数:
242
题目: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).F....
分类:
编程语言 时间:
2014-08-05 05:18:08
阅读次数:
340