原创 LightOJ - 1422 Halloween Costumes 區間DP

Halloween Costumes Time Limit: 2000MS Memory Limit: 32768KB 64bit IO Forma

原创 Generating function

普通篇 HDU1171 #include <iostream> #include <cstdio> #include <cstdlib> using namespace std; int t1[8100],t2[8100] ;

原创 爲了一些不爲什麼的堅持

連興趣都不能堅持,還想做什麼?  爲什麼要問那麼多爲什麼?

原创 Codeforces Round #317 [AimFund Thanks-Round] (Div. 2) B. Order Book

B. Order Book time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard o

原创 HDU 4612 Warm up 樹的最長路徑DP + 無向圖帶重邊

Warm up Time Limit: 10000/5000 MS (Java/Others) Memory Limit: 65535/65535

原创 HDU 4738Caocao's Bridges 鄰接表tarjan 割橋

Caocao's Bridges Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 3276

原创 HDU 5237 Base64

Base64 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others) Total Submission(s): 545 Accep

原创 HDU 5241 Friends

Friends Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 262144/262144 K (Java/Others) Total Submission(s): 556 Ac

原创 ZOJ 3537 Cake 凸包+區間DP+記憶化搜索

CakeZOJ 3537 -------------------------------------------------------------

原创 HDU 5115 Dire Wolf 區間DP+記憶化搜索

Dire Wolf HDU 5115  Time Limit: 5000/5000 MS (Java/Others) Memory Limit: 512000/512000 K (Java/Others) Total Submission

原创 UVa 11624 Fire!

11624 Fire! Joe works in a maze. Unfortunately, portions of the maze have caught on fire, and the owner of the maze neg

原创 凸包 Graham掃描法

凸包函數模板 Graham掃描法 簡單概括就是 排序+掃描 #include <iostream> #include <cstdio> #include <cmath> #include <algorithm> using names

原创 POJ 2955 brackets

Brackets Time Limit: 1000MS Memory Limit: 65536K Description We give the following inductive definition of a “regular

原创 Gauss template

learn from kuangbin #include <iostream> #include <cmath> #include <cstdio> #include <cstdlib> using namespace std;

原创 POJ 2533 Longest Ordered Subsequence

Longest Ordered Subsequence Time Limit: 2000MS Memory Limit: 65536K Total