题目:http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemId=3754 高斯消元好像时间复杂度太高。 注意到每个位置都可以从 dp[ 0 ] 转移过来,所以可以想到每个 dp[ i ] 都可以表示成 a[ i ]*dp[ 0 ] + b[ ...
分类:
其他好文 时间:
2019-01-16 20:41:32
阅读次数:
175
``` Given an array of non-negative integers, you are initially positioned at the first index of the array. Each element in the array represents your m... ...
分类:
其他好文 时间:
2019-01-16 13:13:05
阅读次数:
146
传送门: 题意: 给定一个正n边形的点。双方轮流连点成线,要求所画的线不能与之前的线相交。当某个人连成一个回路,这个人就输了。问先手必胜还是后手必胜。 思路: SG函数,因为一条线相当于把图劈成了两半,所以每次用异或运算推过来。 ...
分类:
其他好文 时间:
2019-01-15 20:29:20
阅读次数:
577
1. Introduction to Design Patterns 2. One Instance to Rule Them All - Singletons 3. Creating Flexibility with the Component Object Model 4. Aritificia ...
分类:
其他好文 时间:
2019-01-15 00:57:01
阅读次数:
123
CONTENT IS KING – BILL GATES (1/3/1996) Content is where I expect much of the real money will be made on the Internet, just as it was in broadcasting. ...
分类:
其他好文 时间:
2019-01-13 17:09:17
阅读次数:
183
[AGC017D]Game on Tree 题目大意: 一棵$n(n\le10^5)$个结点的树。A和B轮流进行游戏,A先手。每次删掉一棵子树,根结点不能删。最先不能操作的人输,问最后谁赢。 思路: 根据树上删边游戏的经典结论,根结点的sg值等于各子结点的sg值+1后的异或和。 源代码: cpp i ...
分类:
其他好文 时间:
2019-01-13 16:09:10
阅读次数:
161
失败的情况有很多种,但成功的路有时候只有一条。在经历了多次失败安装后,特在此将apache安装的精简步骤罗列出来供日后参考。 APACHE 安装方法 1.安装依赖包 wget -c http://archive.apache.org/dist/apr/apr-1.6.2.tar.gz a.安装apr ...
分类:
Web程序 时间:
2019-01-13 14:21:16
阅读次数:
202
Let's play the minesweeper game (Wikipedia, online game)! You are given a 2D char matrix representing the game board. 'M' represents an unrevealed min ...
分类:
其他好文 时间:
2019-01-11 15:58:03
阅读次数:
147
You are policeman and you are playing a game with Slavik. The game is turn-based and each turn consists of two phases. During the first phase you make ...
分类:
其他好文 时间:
2019-01-11 00:47:53
阅读次数:
163
"Probability One" Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 1944 Accepted: 1335 Description Number guessing is a popular game between ...
分类:
其他好文 时间:
2019-01-09 11:44:12
阅读次数:
181