Problem Description Today is the 1st anniversary of BestCoder. Soda, the contest manager, gets a string s of length n. He wants to find three nonoverlapping substrings s[l1..r1], s[l2..r2], s[l3..r3] that: . ≤l1≤r1<l2≤r2<l3≤r3≤n . The concatenation…
题目连接 http://acm.hdu.edu.cn/showproblem.php?pid=5311 Hidden String Description Today is the 1st anniversary of BestCoder. Soda, the contest manager, gets a string s of length n. He wants to find three nonoverlapping substrings $s[l_1..r_1], s[l_2..r_2…
http://acm.hdu.edu.cn/showproblem.php?pid=5311 Hidden String Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 262144/262144 K (Java/Others)Total Submission(s): 1499 Accepted Submission(s): 534 Problem Description Today is the 1st anniversar…
Hidden String Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 262144/262144 K (Java/Others) Total Submission(s): 52 Accepted Submission(s): 25 Problem Description Today is the 1st anniversary of BestCoder. Soda, the contest manager, gets a…
逃离迷宫 Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 13562 Accepted Submission(s): 3221 Problem Description 给定一个m × n (m行, n列)的迷宫,迷宫中有两个位置,gloria想从迷宫的一个位置走到另外一个位置,当然迷宫中有些地方是空地,gloria可以穿越,有些地方…
Pasha and String Time Limit:2000MS Memory Limit:262144KB 64bit IO Format:%I64d & %I64u Submit Status Practice CodeForces 525B Description Pasha got a very beautiful string s for his birthday, the string consists of lowercase Latin letters. Th…
Ice-sugar Gourd Time Limit: 5000/2000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 1490 Accepted Submission(s): 470 Problem Description Ice-sugar gourd, "bing tang hu lu", is a popular snack in Beijing of…
Count the string Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 14368 Accepted Submission(s): 6572 Problem Description It is well known that AekdyCoin is good at string problems as well as number…
#include<iostream> #include<cstring> #include<cmath> #include<cstdio> using namespace std; int cmp(int x)//计算因子数 { int cnt=0; for(int j=1;j<=x;j++) if(x%j==0) cnt++; return cnt; } int main() { int n; int a,b; int cnt,maxn,index;…
HDU 1074 Doing Homework (动态规划,位运算) Description Ignatius has just come back school from the 30th ACM/ICPC. Now he has a lot of homework to do. Every teacher gives him a deadline of handing in the homework. If Ignatius hands in the homework after the d…
POJ 2240 Arbitrage / ZOJ 1092 Arbitrage / HDU 1217 Arbitrage / SPOJ Arbitrage(图论,环) Description Arbitrage is the use of discrepancies in currency exchange rates to transform one unit of a currency into more than one unit of the same currency. For exa…
HDU 3338 Kakuro Extension (网络流,最大流) Description If you solved problem like this, forget it.Because you need to use a completely different algorithm to solve the following one. Kakuro puzzle is played on a grid of "black" and "white" ce…
HDU 4280 Island Transport(网络流,最大流) Description In the vast waters far far away, there are many islands. People are living on the islands, and all the transport among the islands relies on the ships. You have a transportation company there. Some route…
HDU 6187 Destroy Walls (思维,最大生成树) Destroy Walls *Time Limit: 8000/4000 MS (Java/Others) Memory Limit: 132768/132768 K (Java/Others) Total Submission(s): 1784 Accepted Submission(s): 692 * Problem Description Long times ago, there are beautiful histor…
HDU 3567 Eight II(八数码 II) /65536 K (Java/Others) Problem Description - 题目描述 Eight-puzzle, which is also called "Nine grids", comes from an old game. In this game, you are given a 3 by 3 board and 8 tiles. The tiles are numbered from 1 to 8 and…