自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(290)
  • 资源 (1)
  • 收藏
  • 关注

原创 libevet

/* A trivial static http webserver using Libevent's evhttp. This is not the best code in the world, and it does some fairly stupid stuff that you would never want to do in a production webserve...

2018-12-02 15:13:29 610

原创 codeforces 677D. Vanya and Treasure(dp+bfs,黑科技)

题目链接D. Vanya and Treasure time limit per test1.5 seconds memory limit per test256 megabytes inputstandard input outputstandard output Vanya is in the palace that can be represented as a grid n ...

2018-03-23 11:55:01 431

原创 bzoj 3083: 遥远的国度(树上换根操作,树剖+询问整个子树)

bzoj 30833083: 遥远的国度Time Limit: 10 Sec Memory Limit: 1280 MBDescription描述 zcwwzdjn在追杀十分sb的zhx,而zhx逃入了一个遥远的国度。当zcwwzdjn准备进入遥远的国度继续追杀时,守护神RapiD阻拦了zcwwzdjn的去路,他需要zcwwzdjn完成任务后才能进入遥远的国度继续追杀。问题...

2018-03-23 11:53:31 411

原创 codeforces 869E. The Untended Antiquity(二维树状数组,随机化)

codeforces 869EE. The Untended Antiquity time limit per test2 seconds memory limit per test512 megabytes inputstandard input outputstandard output Adieu l’ami.Koyomi is helping Oshino, an acq...

2018-03-23 11:52:03 249

原创 gym 100801G.Graph(拓扑排序,贪心构造)

gym 100801G题意:给出 nnn 个点 mmm 条边的 DAGDAGDAG,要求最多加 kkk 条有向边(不能形成环),使得可能的字典序最小的拓扑序列最大。输出最终最小的拓扑序列,以及加边数,加的边(1≤n≤105,0≤m≤1051≤n≤105,0≤m≤1051 \leq n \leq 10^5,0 \leq m \leq 10^5)题解:用两个优先队列 minQ,maxQ...

2018-03-23 11:50:38 344

原创 hdu 5534 Partial Tree(dp+降唯)

题目链接Partial TreeTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 262144/262144 K (Java/Others) Total Submission(s): 1577 Accepted Submission(s): 789Problem Description In mathematics, and m

2017-11-12 16:36:56 252

原创 Codeforces Round #294 (Div. 2) E. A and B and Lecture Rooms(lca+思维,树上寻找与给定两个点距离相等的点的个数)

E. A and B and Lecture Rooms time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output A and B are preparing themselves for programming cont

2017-11-12 16:35:55 357

原创 51nod 1821 最优集合(想法+贪心+并查集)

1821 最优集合基准时间限制:1 秒 空间限制:131072 KB 分值: 40 难度:4级算法题 收藏 关注一个集合S的优美值定义为:最大的x,满足对于任意i∈[1,x],都存在一个S的子集S',使得S'中元素之和为i。给定n个集合,对于每一次询问,指定一个集合S1和一个集合S2,以及一个数k,要求选择一个S2的子集S3(|S3|

2017-03-16 00:17:13 785

原创 codeforces 733 F. Drivers Dissatisfaction(最小生成树+lca+倍增去环)

 题目链接F. Drivers Dissatisfactiontime limit per test4 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputIn one kingdom there are n cities and m two-w...

2017-03-14 12:46:13 854

原创 codeforces 580 E. Kefa and Watch(hash+线段树)

E. Kefa and Watchtime limit per test1.5 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputOne day Kefa the parrot was walking dow

2017-03-10 00:00:23 403

原创 Yandex.Algorithm 2011 Round 1(STL!)

D. Sum of Medianstime limit per test3 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputIn one well-known algorithm of finding th

2017-03-02 23:50:09 491

原创 gym 101124 Problem E. Dance Party(概率)

Problem E. Dance PartyTime limit: 0.5 secondsMemory limit: 256 megabytesDance parties, whether formal balls or less formal events, usuallyhave dress codes for the guests. The code may be more or l

2017-03-02 23:13:57 753

原创 AtCoder Grand Contest 010 B(差分)

题目链接B - BoxesTime limit : 2sec / Memory limit : 256MBScore : 500 pointsProblem StatementThere are N boxes arranged in a circle. The i-th box contains Ai stones.Determine

2017-03-01 23:36:50 558

原创 Codeforces Round #352 (Div. 1) B. Robin Hood(想法+二分,好题)

题目链接B. Robin Hoodtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputWe all know the impressive story of Ro

2017-03-01 19:10:33 275

原创 codeforces 717 G. Underfail(费用流,好题)

题目链接G. Underfailtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou have recently fallen through a hole

2017-02-28 23:34:49 737

原创 Codeforces Round #268 (Div. 1) C. Hack it!(二分+尺取/构造,好题)

C. Hack it!time limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputLittle X has met the following problem recently.

2017-02-28 16:38:44 398

原创 codeforces 717 D. Dexterina’s Lab(矩阵快速幂加速dp,好题)

题目链接D. Dexterina’s Labtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputDexterina and Womandark have been

2017-02-28 09:28:25 499

原创 Codeforces Round #322 (Div. 2) F. Zublicanes and Mumocrates(树形dp,好题)

题目链接F. Zublicanes and Mumocratestime limit per test3 secondsmemory limit per test512 megabytesinputstandard inputoutputstandard outputIt's election time in

2017-02-27 20:27:36 328

原创 Kattis-Curious Cupid(莫队)

题目链接Curious CupidThere are K different languages in the world. Each person speaks one and only one language. There are exactly N single men and N single women.Cupid, the god of l

2017-02-26 17:46:41 400

原创 Codeforces Round #400 (Div. 1 + Div. 2, combined) D. The Door Problem(二分染色?/2-sat,好题)

题目链接D. The Door Problemtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputMoriarty has trapped n people i

2017-02-24 20:57:46 516

原创 gym 101194 china final Problem H. Great Cells(数学,想法题,好题)

题目链接Problem H. Great Cells Input file:Output file: Time limit:Standard InputStandard Ouptut2 secondsMr. Panda likes playing puzzles with grid paper. Recently he inv

2017-02-24 20:30:17 1268

原创 CROC 2016 - Final Round [Private, For Onsite Finalists Only] B(二分染色? 好题)

题目链接B. Graph Coloringtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou are given an undirected graph

2017-02-24 19:28:06 603

原创 ICM Technex 2017 and Codeforces Round #400 (Div. 1 + Div. 2, combined) C. Molly's Chemicals

题目链接C. Molly's Chemicalstime limit per test2.5 secondsmemory limit per test512 megabytesinputstandard inputoutputstandard outputMolly Hooper has n different

2017-02-24 10:23:17 304

原创 Codeforces Round #257 (Div. 1) C. Jzzhu and Apples(构造题,想法题,好题)

题目链接C. Jzzhu and Applestime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputJzzhu has picked n apples from h

2017-02-23 22:19:52 573

原创 gym 101170 Problem H Hamiltonian Hypercube(找规律?)

题目链接Problem HHamiltonian HypercubeHypercube graphs are fascinatingly regular, hence you have devoted a lot of time studying themathematics related to them. The vertices of a hypercube graph of d

2017-02-23 18:01:47 800

原创 gym101194 china final Problem D. Ice Cream Tower(二分)

题目链接Problem D. Ice Cream Tower Input file:Output file: Time limit:Standard InputStandard Ouptut6 secondsThe 2016 ACM-ICPC Asia China-Final ContestMr. Pa

2017-02-23 11:10:30 1266

原创 gym101194 china final Problem E. Bet(数学,高精度)

题目链接Problem E. Bet Input file:Output file: Time limit:Standard InputStandard Ouptut1 secondThe 2016 ACM-ICPC Asia China-Final ContestThe Codejamongame

2017-02-23 09:58:34 1493

原创 Codeforces Round #398 (Div. 2) E. Change-free(想法题,贪心,好题)

题目链接E. Change-freetime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputStudent Arseny likes to plan his life

2017-02-22 21:41:58 728

原创 hdu 4345 Permutation(数论+dp)

题目链接PermutationTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 835    Accepted Submission(s): 493Problem DescriptionThere

2017-02-22 19:54:12 286

原创 hdu 4348 To the moon(主席树,区间更新节省内存,经典)

题目链接To the moonTime Limit: 4000/2000 MS (Java/Others)    Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 5038    Accepted Submission(s): 1134Problem DescriptionBack

2017-02-22 17:04:39 593

原创 Codeforces Round #176 (Div. 2) D. Shifting(模拟,STLdeque应用)

题目链接D. Shiftingtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputJohn Doe has found the beautiful permut

2017-02-22 15:35:42 427

原创 Codeforces Alpha Round #21 D. Traveling Graph(欧拉路,floyed,dp,好题)

题目链接D. Traveling Graphtime limit per test0.5 secondmemory limit per test64 megabytesinputstandard inputoutputstandard outputYou are given undirected weighte

2017-02-22 11:59:47 296

原创 Codeforces Round #399 D. Jon and Orbs(概率dp,好题)

题目链接D. Jon and Orbstime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputJon Snow is on the lookout for some

2017-02-22 10:10:23 405

原创 SPOJ-TTM - To the moon(主席树,经典)

题目链接TTM - To the moonno tags BackgroundTo The Moon is a independent game released in November 2011, it is a role-playing adventure game powered by RPG Maker.The premise o

2017-02-21 21:15:43 755

原创 Codeforces Round #372 (Div. 2) E. Digit Tree(点分治,好题)

题目链接E. Digit Treetime limit per test3 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputZS the Coder has a large tree. It can

2017-02-21 11:17:44 576

原创 Codeforces Beta Round #3 D. Least Cost Bracket Sequence(贪心,想法,好题)

题目链接D. Least Cost Bracket Sequencetime limit per test1 secondmemory limit per test64 megabytesinputstandard inputoutputstandard outputThis is yet another pr

2017-02-20 20:12:19 340

原创 Codeforces Round #383 (Div. 2) E(贪心,二分图染色,好题)

题目链接E. Arpa’s overnight party and Mehrdad’s silent enteringtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard output

2017-02-20 11:55:18 501

原创 Codeforces Beta Round #50 C. First Digit Law(概率dp,好题)

题目链接C. First Digit Lawtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputIn the probability theory the fo

2017-02-20 10:19:37 282

原创 hdu 5845 Best Division(trie+dp,好题)

Best DivisionTime Limit: 4000/2000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 663    Accepted Submission(s): 199Problem DescriptionYou are give

2017-02-19 22:12:50 585

原创 gym 100820G Racing Gems(二维LIS,好题)

题目链接Racing GemsYou are playing a racing game. Your character starts at thex axis (y= 0) and proceeds up therace track, which has a boundary at the linex = 0 and another atx =w.

2017-02-19 19:55:30 521

空空如也

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

TA关注的人

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