enmmmmmm】 大部分好像除了最后一个思考题都很简单 代码如下 至于最后一个思考题 浮点数陷阱 把 10 改成10.0 10.000000 啥的都没用 脑阔疼 搜了下发现了这个博客 http://blog.sina.com.cn/s/blog_6da76f9b0100yr8d.html 浮点数陷 ...
分类:
编程语言 时间:
2018-10-11 01:37:14
阅读次数:
187
Description Some message encoding schemes require that an encoded message be sent in two parts. The first part, called the header, contains the charac ...
分类:
编程语言 时间:
2018-09-29 20:27:15
阅读次数:
193
Description A research laboratory of a world leading automobile company has received an order to create a special transmission mechanism, which allows ...
分类:
编程语言 时间:
2018-09-22 21:19:35
阅读次数:
292
Description The decimal expansion of the fraction 1/33 is 0.03, where the 03 is used to indicate that the cycle 03 repeats indefinitely with no interv ...
分类:
编程语言 时间:
2018-09-22 14:40:10
阅读次数:
168
Description A crossword puzzle consists of a rectangular grid of black and white squares and two lists of definitions (or descriptions). One list of d ...
分类:
编程语言 时间:
2018-09-21 13:29:07
阅读次数:
188
1. 排序和检索,学会使用sort排序,以及low_bound函数 Raju and Meena love to play with Marbles. They have got a lot of marbles with numbers written on them. At the beginn ...
分类:
编程语言 时间:
2018-09-05 08:56:02
阅读次数:
164
这篇博客主要参考刘汝佳的《算法竞赛入门经典》。 下面是一个杨辉三角: 我们再把(a+b)n展开,将得到一个关于x的多项式: (a+b)0 = 1 (a+b)1 = a + b (a+b)2 = a2 + 2ab + b2 (a+b)3 = a3 + 3a2b + 3ab2 + b3 (a+b)4 = ...
分类:
其他好文 时间:
2018-08-19 21:50:08
阅读次数:
138
今天学习了一下上次集训讲的置换,当时没懂,这个东西确实难理解。。。我看了《算法竞赛入门经典训练指南》,才勉强明白一点基础。。。 学习置换之前先要理解群论: 了解群论之后才进行初步置换。 先举个例子: 表示1被1到n中的某一个数a1取代,2被1到n中的某一个数a2取代,直到n被1到n中的某一个数an取 ...
分类:
其他好文 时间:
2018-08-03 01:00:55
阅读次数:
156
思路:遍历可能的周期,比较s[k]与s[k%i](其中i为周期) ...
分类:
编程语言 时间:
2018-07-23 14:57:58
阅读次数:
140