You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each of their nodes contai ...
分类:
其他好文 时间:
2019-04-09 16:39:39
阅读次数:
167
Calculate a+b and output the sum in standard format -- that is, the digits must be separated into groups of three by commas (unless there are less tha ...
分类:
其他好文 时间:
2019-04-06 09:24:43
阅读次数:
107
Instructions In this kata, you must create a digital root function. A digital root is the recursive sum of all the digits in a number. Given n, take t ...
分类:
编程语言 时间:
2019-04-05 18:24:09
阅读次数:
196
For a non-negative integer X, the array-form of X is an array of its digits in left to right order. For example, if X = 1231, then the array form is [ ...
分类:
其他好文 时间:
2019-04-05 09:24:39
阅读次数:
118
1. 原始题目 You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each of their node ...
分类:
其他好文 时间:
2019-04-04 17:22:26
阅读次数:
126
Given a 32-bit signed integer, reverse digits of an integer. Example 1: Example 2: Example 3: 题意: 给定一个10进制整数,翻转它。 Solution1: directly do the simulatio ...
分类:
其他好文 时间:
2019-04-04 09:16:47
阅读次数:
149
#include <cstdio> #include <algorithm> #include <cstring> #include <iostream> using namespace std; typedef long long ll; const int maxn = 4e4 + 100; i ...
分类:
其他好文 时间:
2019-04-01 01:18:17
阅读次数:
170
Algorithm Leetcode 2. Add Two Numbers You are given two non empty linked lists representing two non negative integers. The digits are stored in revers ...
分类:
其他好文 时间:
2019-03-31 23:16:42
阅读次数:
176
class Solution { public: map dict; vector letterCombinations(string digits) { dict['2'] = "abc"; dict['3'] = "def"; dict['4'] = "ghi"; dict['5'] = "jk... ...
分类:
其他好文 时间:
2019-03-28 18:14:40
阅读次数:
189
Given a non-empty array of digits representing a non-negative integer, plus one to the integer. The digits are stored such that the most significant d ...
分类:
其他好文 时间:
2019-03-28 13:57:21
阅读次数:
168