Implement pow(x, n).刚开始没想到,后来看remlost的博客才写出来,代码很简练:class Solution {public: double pow(double x, int n) { if(n<0) return 1/power(x... Read More
posted @ 2014-08-21 09:54
Xylophone
Views(222)
Comments(0)
Diggs(0)
The n-queens puzzle is the problem of placing n queens on an n×n chessboard such that no two queens attack each other.Given an integer n, return all d... Read More
posted @ 2014-08-21 09:31
Xylophone
Views(133)
Comments(0)
Diggs(0)
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 of... Read More
posted @ 2014-08-21 00:14
Xylophone
Views(111)
Comments(0)
Diggs(0)

浙公网安备 33010602011771号