Basic Calculator II
Implement a basic calculator to evaluate a simple expression string.
The expression string contains only non-negative integers, +, -, *, and / operators. The integer division...
分类:
其他好文 时间:
2015-06-22 14:59:42
阅读次数:
127
Gray Code
欢迎大家阅读参考,如有错误或疑问请留言纠正,谢谢
The gray code is a binary numeral system where two successive values differ in only one bit.
Given a non-negative integer n representing the to...
分类:
其他好文 时间:
2015-06-22 11:11:12
阅读次数:
115
Add Two NumbersYou are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes co...
分类:
编程语言 时间:
2015-06-21 17:03:25
阅读次数:
185
题目链接 题目要求: Given a non-negative number represented as an array of digits, plus one to the number. The digits are stored such that the most signif...
分类:
编程语言 时间:
2015-06-20 11:45:49
阅读次数:
139
对于C(n, m) mod p。这里的n,m,p(p为素数)都很大的情况。就不能再用C(n, m) = C(n - 1,m) + C(n - 1, m - 1)的公式递推了。这里用到Lusac定理For non-negative integersmandnand a primep, the foll...
分类:
其他好文 时间:
2015-06-19 13:23:31
阅读次数:
106
Rotate List
Given a list, rotate the list to the right by k places, where k is non-negative.
For example:
Given 1->2->3->4->5->NULL and k = 2,
return 4->5->1->2->3->NULL.
解题思路:
这道题题意说得不...
分类:
其他好文 时间:
2015-06-18 15:23:28
阅读次数:
115
Given an array of non-negative integers, you are initially positioned at the first index of the array.Each element in the array represents your maximu...
分类:
其他好文 时间:
2015-06-18 00:38:25
阅读次数:
119
题目:Given a non-negative number represented as an array of digits, plus one to the number.The digits are stored such that the most significant digit is...
分类:
其他好文 时间:
2015-06-17 23:23:03
阅读次数:
277
L179:Largest Number
Given a list of non negative integers, arrange them such that they form the largest number. For example, given [3, 30, 34, 5, 9], the largest formed number is 9534330. Note: Th...
分类:
其他好文 时间:
2015-06-17 21:37:46
阅读次数:
102
Given a list of non negative integers, arrange them such that they form the largest number.For example, given[3, 30, 34, 5, 9], the largest formed num...
分类:
其他好文 时间:
2015-06-17 07:08:55
阅读次数:
97