题目连接 题意:计算从a到b每个数每位数字相加的和 code: #include <iostream> #include <cstdio> #include <cstdlib> #include <cstring> using namespace std; typedef unsigned long ...
分类:
其他好文 时间:
2016-07-22 22:51:43
阅读次数:
148
Given two arrays of length m and n with digits 0-9 representing two numbers. Create the maximum number of length k <= m + n from digits of the two. Th ...
分类:
其他好文 时间:
2016-07-22 06:33:15
阅读次数:
297
题目 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 sing ...
分类:
其他好文 时间:
2016-07-20 21:16:02
阅读次数:
218
Given a non-negative integer n, count all numbers with unique digits, x, where 0 ≤ x < 10n. Example:Given n = 2, return 91. (The answer should be the ...
分类:
其他好文 时间:
2016-07-20 11:41:05
阅读次数:
126
Print numbers from 1 to the largest number with N digits by recursion. Notice It's pretty easy to do recursion like: recursion(i) { if i > largest num ...
分类:
其他好文 时间:
2016-07-16 06:51:53
阅读次数:
108
You have two numbers represented by a linked list, where each node contains a single digit. The digits are stored in reverse order, such that the 1's ...
分类:
其他好文 时间:
2016-07-16 06:49:14
阅读次数:
105
Given string A representative a positive integer which has N digits, remove any k digits of the number, the remaining digits are arranged according to ...
分类:
其他好文 时间:
2016-07-15 06:38:15
阅读次数:
190
Given a non-negative integer num, repeatedly add all its digits until the result has only one digit. For example: Given num = 38, the process is like: ...
分类:
其他好文 时间:
2016-07-14 15:03:35
阅读次数:
122
258. Add Digits 258. Add Digits Total Accepted: 108804 Total Submissions: 221342 Difficulty: Easy Given a non-negative integer num, repeatedly add all ...
分类:
其他好文 时间:
2016-07-14 02:29:14
阅读次数:
123