Description
Write a program that finds and displays all pairs of 5-digit numbers that between them use the digits
0 through 9 once each, such that the first number divided by the second is equal...
分类:
其他好文 时间:
2015-07-27 21:04:50
阅读次数:
119
题目如下:
If a machine can save only 3 significant digits, the float numbers 12300 and 12358.9 are considered equal since they are both saved as 0.123*105 with simple chopping. Now given the number o...
分类:
其他好文 时间:
2015-07-27 19:06:41
阅读次数:
115
Given a string containing only digits, restore it by returning all possible valid IP address combinations.
For example:
Given "25525511135",
return ["255.255.11.135", "255.255.111.35"]. (Order...
分类:
其他好文 时间:
2015-07-27 11:12:45
阅读次数:
645
A message containing letters from A-Z is being encoded to numbers using the
following mapping:
'A' -> 1
'B' -> 2
...
'Z' -> 26
Given an encoded message containing digits, determine the total nu...
分类:
其他好文 时间:
2015-07-27 11:12:18
阅读次数:
171
By using each of the digits from the set, {1, 2, 3, 4}, exactly once, and making use of the four arithmetic operations (+, ?, *, /) and brackets/parentheses, it is possible to form
different positiv...
分类:
其他好文 时间:
2015-07-26 19:21:34
阅读次数:
378
Description
The digital difference of a positive number is constituted by the difference between each two neighboring digits (with the leading zeros omitted). For example the digital difference of 113...
分类:
其他好文 时间:
2015-07-26 17:30:30
阅读次数:
111
A number chain is created by continuously adding the square of the digits in a number to form a new number until it has been seen before.
For example,
44 → 32 → 13 → 10 → 1 → 1
85 → 89 → 145 → 42...
分类:
其他好文 时间:
2015-07-26 15:52:18
阅读次数:
152
Given a binary tree containing digits from 0-9 only, each root-to-leaf path
could represent a number.
An example is the root-to-leaf path 1->2->3 which represents the number 123.
Find the tota...
分类:
其他好文 时间:
2015-07-26 15:50:28
阅读次数:
113
暴力搜索。注意题目说每个字母对应的数字不同,这句话表明最多只有10个字母,所以暴力DFS绝对不会TLE。#include#include#include#includeusing namespace std;char s[1000],t[1000];char cun[1000];int C[1000...
分类:
其他好文 时间:
2015-07-26 09:45:41
阅读次数:
129
LeetCode 2_Add Two Numbers
题目描述:
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. Ad...
分类:
其他好文 时间:
2015-07-26 06:14:59
阅读次数:
131