上一页 1 ··· 59 60 61 62 63 64 65 66 67 ··· 94 下一页

2012年8月15日

HDU 1540 Tunnel Warfare(线段树,去最大连续区间)

摘要: Tunnel WarfareTime Limit: 4000/2000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 2396Accepted Submission(s): 886Problem DescriptionDuring the War of Resistance Against Japan, tunnel warfare was carried out extensively in the vast areas of north China Plain. Generally 阅读全文

posted @ 2012-08-15 21:55 kuangbin 阅读(4958) 评论(0) 推荐(2) 编辑

POJ 2063 Investment(完全背包)

摘要: InvestmentTime Limit: 1000MSMemory Limit: 30000KTotal Submissions: 5362Accepted: 1843DescriptionJohn never knew he had a grand-uncle, until he received the notary's letter. He learned that his late grand-uncle had gathered a lot of money, somewhere in South-America, and that John was the only in 阅读全文

posted @ 2012-08-15 11:53 kuangbin 阅读(646) 评论(1) 推荐(0) 编辑

HDU 1698 Just a Hook(线段树,成段更新)

摘要: Just a HookTime Limit: 4000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 9258Accepted Submission(s): 4510Problem DescriptionIn the game of DotA, Pudge’s meat hook is actually the most horrible thing for most of the heroes. The hook is made up of several consecut 阅读全文

posted @ 2012-08-15 02:57 kuangbin 阅读(2448) 评论(0) 推荐(0) 编辑

HDU 1394 Minimum Inversion Number(求逆序数,线段树或者树状数组)

摘要: Minimum Inversion NumberTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 4647Accepted Submission(s): 2809Problem DescriptionThe inversion number of a given number sequence a1, a2, ..., an is the number of pairs (ai, aj) that satisfy i < j and ai 阅读全文

posted @ 2012-08-15 02:11 kuangbin 阅读(3985) 评论(0) 推荐(1) 编辑

2012年8月14日

HDU 4251 The Famous ICPC Team Again(划分树入门题)

摘要: The Famous ICPC Team AgainTime Limit: 30000/15000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 438Accepted Submission(s): 193Problem DescriptionWhen Mr. B, Mr. G and Mr. M were preparing for the 2012 ACM-ICPC World Final Contest, Mr. B had collected a large set of co 阅读全文

posted @ 2012-08-14 23:12 kuangbin 阅读(723) 评论(0) 推荐(0) 编辑

HDU 2665 Kth number(划分树入门题,纯套模板)

摘要: Kth numberTime Limit: 15000/5000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2026Accepted Submission(s): 672Problem DescriptionGive you a sequence and ask you the kth big number of a inteval.InputThe first line is the number of the test cases. For each test case, th 阅读全文

posted @ 2012-08-14 21:01 kuangbin 阅读(1931) 评论(0) 推荐(0) 编辑

KMP算法

摘要: 假设主串:S: S[1] S[2] S[3] ……S[n]模式串:T: T[1] T[2] T[3]…..T[m]现在我们假设主串第i 个字符与模式串的第j(j<=m)个字符‘失配’后,主串第i 个字符与模式串的第k(k<j)个字符继续比较,此时就有S[i] != T[j]主串: S[1]...S[i-j+1]...S[i-1]S[i]... ||(匹配) || ≠模式串: T[1]... T[j-1] T[j]由此,可以得到关系式如下 T[1]T[2]T[3]...T[j-1] = S[i-j+1]...S[i-1]由于S[i] != T[j],接下来S[i]将与T[k]继续比较 阅读全文

posted @ 2012-08-14 20:33 kuangbin 阅读(10764) 评论(0) 推荐(2) 编辑

HDU 1044 Collect More Jewels(搜索,先bfs再dfs)

摘要: Collect More JewelsTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 2932Accepted Submission(s): 547Problem DescriptionIt is written in the Book of The Lady: After the Creation, the cruel god Moloch rebelled against the authority of Marduk the Creato 阅读全文

posted @ 2012-08-14 10:01 kuangbin 阅读(1809) 评论(0) 推荐(1) 编辑

2012年8月13日

POJ 3295 Tautology(构造法)

摘要: TautologyTime Limit: 1000MSMemory Limit: 65536KTotal Submissions: 6088Accepted: 2315DescriptionWFF 'N PROOF is a logic game played with dice. Each die has six faces representing some subset of the possible symbols K, A, N, C, E, p, q, r, s, t. A Well-formed formula (WFF) is any string of these s 阅读全文

posted @ 2012-08-13 18:30 kuangbin 阅读(1647) 评论(0) 推荐(1) 编辑

POJ 2993 Emag eht htiw Em Pleh(水模拟)

摘要: Emag eht htiw Em PlehTime Limit: 1000MSMemory Limit: 65536KTotal Submissions: 1950Accepted: 1315DescriptionThis problem is a reverse case of the problem 2996. You are given the output of the problem H and your task is to find the corresponding input.Inputaccording to output of problem 2996.Outputacc 阅读全文

posted @ 2012-08-13 16:44 kuangbin 阅读(853) 评论(0) 推荐(0) 编辑

上一页 1 ··· 59 60 61 62 63 64 65 66 67 ··· 94 下一页

导航

JAVASCRIPT: