原创 hdu 3395 Special Fish
題目鏈接:http://acm.hdu.edu.cn/showproblem.php?pid=3395 題目大意:求交配後代 的最大值,注意每隻魚最多攻擊別的一次和被攻擊一次 題目思路:可能交配的魚之間連邊,用最大權匹配,KM算法 原題
原创 zoj 2851 Code Formatter
Code Formatter Time Limit: 2 Seconds Memory Limit: 65536 KB Some companies have special requirements for source
原创 hdu 1569 方格取數(2)
題目鏈接:http://acm.hdu.edu.cn/showproblem.php?pid=1569 題目思路: 因爲這個數據比較大,所以用動態規劃會超時。 將圖轉換成黑白棋盤問題,i + j 爲奇數的與s節點相連,邊的權值爲棋盤上對應
原创 hdu 1285 確定比賽名次
確定比賽名次 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 7059
原创 A. You're Given a String...
A. You're Given a String... time limit per test 2 seconds memory limit per test 256 megabytes input standard in
原创 B. Party
B. Party time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard ou
原创 C. Oranges and Apples
C. Oranges and Apples time limit per test 2 seconds memory limit per test 256 megabytes input standard input outpu
原创 hdu 3342 Legal or Not
Legal or Not Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 2
原创 hdu 1530 Maximum Clique
Maximum Clique Time Limit: 20000/10000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s
原创 最長公共子序列
若給定序列X={x1,x2,…,xm},則另一序列 Z={z1,z2,…,zk},是X的子序列是指存在一個嚴格遞增下 標序列{i1,i2,…,ik}
原创 hdu 3251 Being a Hero
題目: Being a Hero Time Limit: 20000/10000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submissio
原创 D. Tetragon
D. Tetragon time limit per test 3 seconds memory limit per test 256 megabytes input standard input output standard
原创 poj 1015 Jury Compromise
鏈接:http://poj.org/problem?id=1015 題目大意:求兩組中m個的和之後的差最小, 題目思路:動態規劃,可行方案dp(j-1, x)能演化成方案dp(j, k)的必要條件是:存在某個候選人i,i 在方案dp(j-
原创 pku Graph Coloring
Graph Coloring Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 3352 Accepted: 1497 Special Judge Des
原创 Pick apples
原題 Pick apples Time Limit: 1000MS Memory limit: 165536K 題目描述 Once ago, there is a mystery yard which only pr