LeetCode_Count and Say...
分类:
其他好文 时间:
2015-05-14 16:29:46
阅读次数:
123
代码: 1 #include 2 #include 3 #include 4 5 using namespace std; 6 7 8 string countAndSay(int n) 9 {10 string s = "1";11 int i = 0; 12 wh...
分类:
其他好文 时间:
2015-05-13 16:20:42
阅读次数:
91
题目:The count-and-say sequence is the sequence of integers beginning as follows:1, 11, 21, 1211, 111221, ...1is read off as"one 1"or11.11is read off as...
分类:
其他好文 时间:
2015-05-11 20:03:26
阅读次数:
109
The count-and-say sequence is the sequence of integers beginning as follows:1, 11, 21, 1211, 111221, ...1 is read off as "one 1" or 11.11 is read off ...
分类:
编程语言 时间:
2015-05-09 17:25:14
阅读次数:
161
The count-and-say sequence is the sequence of integers beginning as follows:
1, 11, 21, 1211, 111221, …1 is read off as “one 1” or 11.
11 is read off as “two 1s” or 21.
21 is read off as “one 2, the...
分类:
其他好文 时间:
2015-05-07 22:13:13
阅读次数:
111
The count-and-say sequence is the sequence of integers beginning as follows:
1, 11, 21, 1211, 111221, ...
1 is read off as "one
1" or 11.
11 is read off as "two
1s" or 21.
21 is read off as ...
分类:
其他好文 时间:
2015-05-07 10:27:50
阅读次数:
85
https://leetcode.com/problems/count-and-say/The count-and-say sequence is the sequence of integers beginning as follows:1, 11, 21, 1211, 111221, ...1i...
分类:
其他好文 时间:
2015-05-05 23:21:15
阅读次数:
121
The count-and-say sequence is the sequence of integers beginning as follows:
1, 11, 21, 1211, 111221, ...
1 is read off as "one
1" or 11.
11 is read off as "two
1s" or 21.
21 is read off as ...
分类:
其他好文 时间:
2015-05-03 22:10:38
阅读次数:
106
题目思路这个题目是一个easy级别,算法本身没有难点,但是C++的语法有几点需要注意。下面分别说一下:LeetCode中给的C++函数原型是这样的string countAndSay(int n); 也就是说给一个n得到一个string类型的数字串,但是n和这个数字串似乎没有什么关系,这个数字串是....
分类:
其他好文 时间:
2015-04-29 13:07:25
阅读次数:
129
leetcode -Count and SayQ:The count-and-say sequence is the sequence of integers beginning as follows:1, 11, 21, 1211, 111221, ...1is read off as"one 1...
分类:
其他好文 时间:
2015-04-29 00:28:16
阅读次数:
142