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-05-16 23:18:16
阅读次数:
360
[root@www ~]# col [-xb]选项与参数:-x :将 tab
键转换成对等的空格键-b :过滤掉所有的控制字符,包括RLF(Reverse Line Feed)和HRF(Halt RLF)范例一:利用 cat -A
显示出所有特殊按键,最后以 col 将 [tab] 转成空白[r.....
分类:
系统相关 时间:
2014-05-16 19:12:22
阅读次数:
349
题目: Evaluate the value of an arithmetic expression
inReverse Polish Notation.Valid operators are+,-,*,/. Each operand may be an
integer or another e.....
分类:
其他好文 时间:
2014-05-16 05:56:07
阅读次数:
221
题目: Given an input string, reverse the string word
by word. For example, Given s = "the sky is blue", return "blue is sky
the".解题思路: 1、先对字符串进行一次总...
分类:
其他好文 时间:
2014-05-16 05:44:30
阅读次数:
263
题意:给定一棵二叉树,返回按zigzag层次遍历的结果
思路:
还是跟前面的Binary Tree Level Order Traversal的思路一样
即从上往下按层遍历二叉树,将每一层的节点存放到该层对应的数组中
最后将得到的总数组中奇数层(从0层开始计数)的子数组reverse一下就可以了
复杂度:时间O(n),空间O(n)...
分类:
其他好文 时间:
2014-05-15 15:15:50
阅读次数:
374
【题目】
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 digit. Add the two numbers and return it as a linked list.
Input: (2 -> 4 -> 3) + (5 -> 6 -> 4)
Out...
分类:
其他好文 时间:
2014-05-15 05:13:49
阅读次数:
306
本文为senlie原创,转载请保留此地址:http://blog.csdn.net/zhengsenlie
Reverse Integer
Total Accepted: 17472 Total
Submissions: 43938
Reverse digits of an integer.
Example1: x = 123, return 32...
分类:
其他好文 时间:
2014-05-14 00:59:13
阅读次数:
369
题目:Given an input string, reverse the string word
by word.For example,Given s = "the sky is blue",return "blue is sky
the".Clarification:What constitu...
分类:
其他好文 时间:
2014-05-13 22:45:04
阅读次数:
317
题目:Evaluate the value of an arithmetic expression
inReverse Polish Notation.Valid operators are+,-,*,/. Each operand may be an
integer or another expr...
分类:
其他好文 时间:
2014-05-13 22:43:01
阅读次数:
335
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-05-11 18:15:52
阅读次数:
300