自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(25)
  • 收藏
  • 关注

原创 bzoj 1202 狡猾的商人 【并查集】

1202: [HNOI2005]狡猾的商人Time Limit: 10 Sec  Memory Limit: 162 MBSubmit: 4641  Solved: 2283[Submit][Status][Discuss]Description刁姹接到一个任务,为税务部门调查一位商人的账本,看看账本是不是伪造的。账本上记录了n个月以来的收入情况,其中第i 个月的收入额为Ai(i=...

2018-07-31 22:10:19 203

原创 ZOJ 2770 Burn the Linked Camp 【差分约束】

It is well known that, in the period of The Three Empires, Liu Bei, the emperor of the Shu Empire, was defeated by Lu Xun, a general of the Wu Empire. The defeat was due to Liu Bei's wrong decision th...

2018-07-31 08:19:01 180

原创 POJ 3159 Candies 【差分约束】

CandiesTime Limit: 1500MS   Memory Limit: 131072K Total Submissions: 36441   Accepted: 10243 DescriptionDuring the kindergarten days, flymouse was the monitor of his class. Occasio...

2018-07-30 21:44:32 169

原创 HDU 6324 Problem F. Grab The Tree【博弈】

Problem F. Grab The TreeTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 524288/524288 K (Java/Others)Total Submission(s): 136    Accepted Submission(s): 97 Problem DescriptionLittle Q ...

2018-07-30 21:04:08 277

原创 HDU 6322 Problem D. Euler Function【规律】

Problem D. Euler FunctionTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 524288/524288 K (Java/Others)Total Submission(s): 98    Accepted Submission(s): 91 Problem DescriptionIn number...

2018-07-30 21:01:07 297

原创 POJ 1716 Integer Intervals 【差分约束】

Integer IntervalsTime Limit: 1000MS   Memory Limit: 10000K Total Submissions: 15647   Accepted: 6631 DescriptionAn integer interval [a,b], a < b, is a set of all consecutive int...

2018-07-30 20:57:42 188

原创 POJ 3436 ACM Computer Factory 【最大流】【路径】

ACM Computer FactoryTime Limit: 1000MS   Memory Limit: 65536K Total Submissions: 9189   Accepted: 3385   Special Judge DescriptionAs you know, all the computers used for ACM ...

2018-07-29 15:46:02 160

原创 POJ 1459 Power Network 【最大流】

Power NetworkTime Limit: 2000MS   Memory Limit: 32768K Total Submissions: 30415   Accepted: 15681 DescriptionA power network consists of nodes (power stations, consumers and dispat...

2018-07-29 11:11:05 159

原创 POJ 3020 Antenna Placement 【二分图】【最小路径覆盖】

Antenna PlacementTime Limit: 1000MS   Memory Limit: 65536K Total Submissions: 10774   Accepted: 5301 DescriptionThe Global Aerial Research Centre has been allotted the task of buil...

2018-07-29 09:53:52 168

原创 牛客网暑期ACM多校训练营(第四场)G Maximum Mode 【枚举】

链接:https://www.nowcoder.com/acm/contest/142/G来源:牛客网 时间限制:C/C++ 1秒,其他语言2秒空间限制:C/C++ 131072K,其他语言262144K64bit IO Format: %lld题目描述The mode of an integer sequence is the value that appears most ...

2018-07-28 22:13:46 257

原创 POJ 3041Asteroids 【二分图】【最小点覆盖】

AsteroidsTime Limit: 1000MS   Memory Limit: 65536K Total Submissions: 25922   Accepted: 14008 DescriptionBessie wants to navigate her spaceship through a dangerous asteroid field i...

2018-07-28 09:03:11 135

原创 POJ 1094 Sorting It All Out 【拓扑排序】

Sorting It All OutTime Limit: 1000MS   Memory Limit: 10000K Total Submissions: 38571   Accepted: 13588 DescriptionAn ascending sorted sequence of distinct values is one in which so...

2018-07-28 08:13:25 154

原创 POJ Borg Maze 【BFS + 最小生成树】

Borg MazeTime Limit: 1000MS   Memory Limit: 65536K Total Submissions: 17025   Accepted: 5497 DescriptionThe Borg is an immensely powerful race of enhanced humanoids from the delta ...

2018-07-27 20:09:59 192

原创 C++ rope 学习

#include<ext/rope>///头文件using namespace __gnu_cxx;rope <int> x;int main(){ x.push_back(x); ///在末尾加x x.insert(pos, x); ///在pos位置加入x x.erase(pos, x); ///从pos位置删除x个元素 x.co...

2018-07-27 14:53:54 1989

原创 HDU 6315 Naive Operations 【线段树】【树状数组】

Naive Operations Time Limit: 6000/3000 MS (Java/Others)    Memory Limit: 502768/502768 K (Java/Others) Total Submission(s): 1620    Accepted Submission(s): 689   Problem Description ...

2018-07-26 17:13:24 205

原创 POJ 1258 Agri-Net 【最小生成树】

Agri-NetTime Limit: 1000MS   Memory Limit: 10000K Total Submissions: 67336   Accepted: 27876 DescriptionFarmer John has been elected mayor of his town! One of his campaign promises...

2018-07-25 15:41:46 145

原创 POJ 1789 Truck History 【最小生成树】

#include<cstdio>#include<algorithm>using namespace std;const int MAX = 2e6 + 7;int pre[MAX];struct node{ int x, y, len; bool operator < (const node &a) const{ ...

2018-07-25 10:34:16 139

原创 HDU 6299 Balanced Sequence 【贪心】

Balanced Sequence Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 2182    Accepted Submission(s): 537   Problem Description ...

2018-07-24 14:39:18 165

原创 HDU 6301Distinct Values 【贪心】

Distinct Values Time Limit: 4000/2000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 1833    Accepted Submission(s): 577   Problem Description C...

2018-07-24 11:11:57 233

原创 POJ 1125 Stockbroker Grapevine 【最短路】【Floyd】

Stockbrokers are known to overreact to rumours. You have been contracted to develop a method of spreading disinformation amongst the stockbrokers to give your employer the tactical edge in the stock m...

2018-07-22 18:37:29 147

原创 牛客网暑期ACM多校训练营(第一场)J Different Integers 【离线】【树状数组】

链接:https://www.nowcoder.com/acm/contest/139/J来源:牛客网 时间限制:C/C++ 2秒,其他语言4秒空间限制:C/C++ 524288K,其他语言1048576K64bit IO Format: %lld题目描述Given a sequence of integers a1, a2, ..., an and q pairs of in...

2018-07-22 18:18:07 153

原创 BZOJ 2038 小z的袜子 【莫队】

2038: [2009国家集训队]小Z的袜子(hose)Time Limit: 20 Sec  Memory Limit: 259 MBSubmit: 14947  Solved: 6840[Submit][Status][Discuss]Description作为一个生活散漫的人,小Z每天早上都要耗费很久从一堆五颜六色的袜子中找出一双来穿。终于有一天,小Z再也无法忍受这恼人的找袜...

2018-07-22 15:51:40 115

原创 POJ 1062 最贵的婚礼 【最短路】

年轻的探险家来到了一个印第安部落里。在那里他和酋长的女儿相爱了,于是便向酋长去求亲。酋长要他用10000个金币作为聘礼才答应把女儿嫁给他。探险家拿不出这么多金币,便请求酋长降低要求。酋长说:"嗯,如果你能够替我弄到大祭司的皮袄,我可以只要8000金币。如果你能够弄来他的水晶球,那么只要5000金币就行了。"探险家就跑到大祭司那里,向他要求皮袄或水晶球,大祭司要他用金币来换,或者替他弄来其他的东西,...

2018-07-22 14:17:40 92

原创 CF 86D Powerful array 【莫队】

D. Powerful arraytime limit per test5 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputAn array of positive integers a1, a2, ..., an is given. Let us ...

2018-07-21 10:14:52 156

原创 SPOJ DOUERY query 【莫队】

Given a sequence of n numbers a1, a2, ..., an and a number of d-queries. A d-query is a pair (i, j) (1 ≤ i ≤ j ≤ n). For each d-query (i, j), you have to return the number of distinct elements in the ...

2018-07-19 16:42:12 148

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除