上一页 1 ··· 12 13 14 15 16 17 18 19 20 ··· 40 下一页

2013年7月25日

[置顶] 【专题】单调队列/斜率优化DP

摘要: 一、单调队列志愿者选拔O(n)struct STU{ char name[7]; int rp; }; int que[2111111]; int idx[2111111]; int main() { int T,head,tail; char gs[111]; scanf("%d",&T); while (T--) { int cas,cnt; head=tail=0; cas=cnt=0; while (scanf("%s",gs)) { ... 阅读全文

posted @ 2013-07-25 11:04 电子幼体 阅读(127) 评论(0) 推荐(0) 编辑

【专题】单调队列/斜率优化DP

摘要: 一、单调队列志愿者选拔O(n)struct STU{ char name[7]; int rp;};int que[2111111];int idx[2111111];int main(){ int T,head,tail; char gs[111]; scanf("%d",&T); while (T--) { int cas,cnt; head=tail=0; cas=cnt=0; while (scanf("%s",gs)) { if (strcmp(gs,... 阅读全文

posted @ 2013-07-25 11:04 电子幼体 阅读(179) 评论(0) 推荐(0) 编辑

MUTC8 E- One hundred layer 单调队列dp

摘要: One hundred layerTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 1257Accepted Submission(s): 467Problem DescriptionNow there is a game called the new man down 100th floor. The rules of this game is: 1.At first you are at the 1st floor. And the flo. 阅读全文

posted @ 2013-07-25 10:55 电子幼体 阅读(162) 评论(0) 推荐(0) 编辑

MUTC8 J-The More The Better

摘要: The More The BetterTime Limit: 4000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2568Accepted Submission(s): 668Problem DescriptionGiven an sequence of numbers {X1, X2, ... , Xn}, where Xk= (A * k + B) % mod. Your task is to find the maximum sub sequence {Y1, Y2 阅读全文

posted @ 2013-07-25 10:53 电子幼体 阅读(186) 评论(0) 推荐(0) 编辑

2013年7月24日

RMQ 模板

摘要: 一维模板const int maxn=50001; class CRMQ { private: int Max[20][maxn]; int Min[20][maxn]; int idx[maxn]; public: int val[maxn]; void initRMQ(int n) { idx[0]=-1; for (int i=1; i>1)]); Max[i][j]=max(Max[i-1][j],Max[i-1][j+(1>1)]); ... 阅读全文

posted @ 2013-07-24 16:22 电子幼体 阅读(131) 评论(0) 推荐(0) 编辑

poj 2449 k短路--模板

摘要: Remmarguts' DateTime Limit:4000MSMemory Limit:65536KTotal Submissions:17853Accepted:4879Description"Good man never makes girls wait or breaks an appointment!" said the mandarin duck father. Softly touching his little ducks' head, he told them a story."Prince Remmarguts lives i 阅读全文

posted @ 2013-07-24 15:08 电子幼体 阅读(122) 评论(0) 推荐(0) 编辑

MUTC2013 E-Deque-hdu 4604

摘要: DequeTime Limit: 4000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 786Accepted Submission(s): 253Problem DescriptionToday, the teacher gave Alice extra homework for the girl weren't attentive in his class. It's hard, and Alice is going to turn to you for 阅读全文

posted @ 2013-07-24 14:37 电子幼体 阅读(159) 评论(0) 推荐(0) 编辑

MUTC7 C - Dragon Ball 单调队列dp

摘要: Dragon BallTime Limit: 3000/1500 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 1680Accepted Submission(s): 614Problem DescriptionSean has got a Treasure map which shows when and where the dragon balls will appear. some dragon balls will appear in a line at the same ti 阅读全文

posted @ 2013-07-24 11:52 电子幼体 阅读(162) 评论(0) 推荐(0) 编辑

MUTC7 A-As long as Binbin loves Sangsang

摘要: As long as Binbin loves SangsangTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 2053Accepted Submission(s): 501Problem DescriptionBinbin misses Sangsang so much. He wants to meet with Sangsang as soon as possible.Now Binbin downloads a map from ELG 阅读全文

posted @ 2013-07-24 10:43 电子幼体 阅读(193) 评论(0) 推荐(0) 编辑

2013年7月23日

MUTC2013 J-I-number-hdu4608

摘要: I-numberTime Limit: 10000/5000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 195Accepted Submission(s): 75Problem DescriptionThe I-number of x is defined to be an integer y, which satisfied the the conditions below:1.y>x;2.the sum of each digit of y(under base 10) 阅读全文

posted @ 2013-07-23 19:32 电子幼体 阅读(252) 评论(0) 推荐(0) 编辑

上一页 1 ··· 12 13 14 15 16 17 18 19 20 ··· 40 下一页

导航