上一页 1 ··· 3 4 5 6 7 8 9 10 11 下一页
摘要: Description 给出N个数,求第a个数到第b个数之间最大的数减去最小的数的结果 Input N(N小于100,000),M(M小于100,000)接下来有N个数接下来M组范围,所有数均在[0,231-1]内每个范围有2个整数a,b(1<=a<=b<=N) Output 每行输出一个结果 Sa 阅读全文
posted @ 2017-02-23 14:59 Robin! 阅读(158) 评论(0) 推荐(0) 编辑
摘要: Description 顺利潜入勺林寺几天后,方丈给了西瓜一个光荣而艰巨的任务——打扫寺庙中的道路。同时给了西瓜一张勺林寺的地图。西瓜这才知道,勺林寺中总共有n座房子,但道路只有n-1条,这n-1条道路连接了寺中的所有房子,即保证在任何两座房子都能沿着道路抵达。好在西瓜人缘不错,他知道每座房子中都有 阅读全文
posted @ 2017-02-23 00:24 Robin! 阅读(159) 评论(0) 推荐(0) 编辑
摘要: Problem Description Nowadays, we all know that Computer College is the biggest department in HDU. But, maybe you don't know that Computer College had 阅读全文
posted @ 2017-02-21 23:31 Robin! 阅读(137) 评论(0) 推荐(0) 编辑
摘要: Problem Description In 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 阅读全文
posted @ 2017-02-21 17:58 Robin! 阅读(203) 评论(0) 推荐(0) 编辑
摘要: 1 #include 2 using namespace std; 3 #define M(a, b) memset(a, b, sizeof(a)); 4 const int maxn = 1000 + 10; 5 6 struct AhoCorasickAutomata { 7 int ch[maxn][26], val[maxn], last[maxn], f[ma... 阅读全文
posted @ 2017-02-20 20:41 Robin! 阅读(497) 评论(0) 推荐(0) 编辑
摘要: Problem Description A lot of battleships of evil are arranged in a line before the battle. Our commander decides to use our secret weapon to eliminate 阅读全文
posted @ 2017-02-20 17:36 Robin! 阅读(198) 评论(0) 推荐(0) 编辑
摘要: Problem Description 很多学校流行一种比较的习惯。老师们很喜欢询问,从某某到某某当中,分数最高的是多少。这让很多学生很反感。不管你喜不喜欢,现在需要你做的是,就是按照老师的要求,写一个程序,模拟老师的询问。当然,老师有时候需要更新某位同学的成绩。 Input 本题目包含多组测试,请 阅读全文
posted @ 2017-02-18 22:40 Robin! 阅读(145) 评论(0) 推荐(0) 编辑
摘要: Problem Description A group of researchers are designing an experiment to test the IQ of a monkey. They will hang a banana at the roof of a building, 阅读全文
posted @ 2017-02-17 22:01 Robin! 阅读(137) 评论(0) 推荐(0) 编辑
摘要: Problem Description C国的死对头A国这段时间正在进行军事演习,所以C国间谍头子Derek和他手下Tidy又开始忙乎了。A国在海岸线沿直线布置了N个工兵营地,Derek和Tidy的任务就是要监视这些工兵营地的活动情况。由于采取了某种先进的监测手段,所以每个工兵营地的人数C国都掌握的 阅读全文
posted @ 2017-02-17 21:01 Robin! 阅读(102) 评论(0) 推荐(0) 编辑
摘要: 模板1:点修改:支持查询,更新; 1 #include<bits/stdc++.h> 2 using namespace std; 3 #define INF 0x3f3f3f3f 4 const int maxn = 1000 + 10; 5 int a[maxn], qL, qR, p, v; 阅读全文
posted @ 2017-02-16 22:05 Robin! 阅读(128) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 下一页