自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

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

原创 HDU5113 Black And White

In mathematics, the four color theorem, or the four color map theorem, states that, given any separation of a plane into contiguous regions, producing a figure called a map, no more than four colors a...

2018-11-03 21:14:28 233 1

原创 Beauty Contest POJ2187

Beauty ContestTime Limit: 3000MS   Memory Limit: 65536K Total Submissions: 43065   Accepted: 13331 DescriptionBessie, Farmer John's prize cow, has just won first place in a bovine ...

2018-10-23 20:58:14 177

原创 POJ - 1265 Area (pick定理)

Being well known for its highly innovative products, Merck would definitely be a good target for industrial espionage. To protect its brand-new research and development facility the company has instal...

2018-10-19 20:53:52 226

原创 POJ - 1654 Area (初入几何)

You are going to compute the area of a special kind of polygon. One vertex of the polygon is the origin of the orthogonal coordinate system. From this vertex, you may go step by step to the following ...

2018-10-19 11:00:28 198

转载 hdu6395 Sequence

转载地址:https://blog.csdn.net/yiyily/article/details/81666495SequenceTime Limit: 4000/2000 MS (Java/Others)    Memory Limit: 262144/262144 K (Java/Others)Total Submission(s): 1162    Accepted Submis...

2018-08-15 10:54:35 264

转载 hdu6373

唉,高中知识忘完了转载地址:https://blog.csdn.net/lyf04210031/article/details/81516130PinballTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 262144/262144 K (Java/Others)Total Submission(s): 261    A...

2018-08-11 17:52:33 281

转载 HDU 6362

这场比赛充分暴露了我是学渣的事实转载地址:https://blog.csdn.net/codeswarrior/article/details/81515593oval-and-rectanglePatrick Star find an oval.The half of longer axes is on the x-axis with length a.The half of...

2018-08-11 17:36:30 218

原创 HDU3530 Subsequence

SubsequenceTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 8707    Accepted Submission(s): 2928 Problem DescriptionThere is a sequence o...

2018-08-11 11:21:30 195

转载 单调栈,单调队列的入门

转载地址:https://www.cnblogs.com/tham/p/8038828.html我自己的话单调栈是也用数组模拟出来的,我是根据这个博客学的,原理挺简单的,但是做题思想的转变有点麻烦,最后数组模拟的单调队列其实是双向队列。下边是大佬的博客:单调队列是什么呢?可以直接从问题开始来展开。Poj 2823给定一个数列,从左至右输出每个长度为m的数列段内的最小数和最大数。数列...

2018-08-04 12:10:51 145

原创 POJ2559 Largest Rectangle in a Histogram

Largest Rectangle in a HistogramTime Limit: 1000MS   Memory Limit: 65536K Total Submissions: 25861   Accepted: 8377 DescriptionA histogram is a polygon composed of a sequence of re...

2018-08-04 12:06:17 113

转载 HDU6315 Naive Operations

看到大佬的博客我才做出来这道题,转载一波转载地址:https://blog.csdn.net/fire_to_cheat_/article/details/81252648/*hdu 1007首先我们在建立线段树之前应该思考的是线段树的节点维护一个什么值,在比赛过程中,我想到了维护a[i]的值但是时间复杂度太高,又想到维护a[i]/b[i]但是取下整,这样的话无法更新∑的值。在题...

2018-07-31 18:02:23 169

原创 POJ - 3083 Children of the Candy Corn

Children of the Candy CornTime Limit: 1000MS   Memory Limit: 65536K Total Submissions: 15219   Accepted: 6553 DescriptionThe cornfield maze is a popular Halloween treat. Visitors a...

2018-07-27 18:34:56 176

原创 POJ - 1321 棋盘问题

棋盘问题Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 64089   Accepted: 30647 Description在一个给定形状的棋盘(形状可能是不规则的)上面摆放棋子,棋子没有区别。要求摆放时任意的两个棋子不能放在棋盘中的同一行或者同一列,请编程求解对于给定形状和大小的棋...

2018-07-25 10:44:22 111

原创 POJ - 2488 A Knight's Journey

A Knight's JourneyTime Limit: 1000MS   Memory Limit: 65536K Total Submissions: 51329   Accepted: 17399 DescriptionBackground The knight is getting bored of seeing the same black a...

2018-07-25 09:16:28 162

原创 HDU - 1180 诡异的楼梯

诡异的楼梯Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 131072/65536 K (Java/Others)Total Submission(s): 18374    Accepted Submission(s): 4858 Problem DescriptionHogwarts正式开学以后,Harry发现在Ho...

2018-07-21 17:49:08 200

原创 HDU - 1242 Rescue

RescueTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 36265    Accepted Submission(s): 12541 Problem DescriptionAngel was caught by the ...

2018-07-21 10:49:48 127

原创 HDU - 1312 Red and Black

Red and BlackTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 25283    Accepted Submission(s): 15239 Problem DescriptionThere is a rectan...

2018-07-19 12:03:25 99

原创 Nightmare HDU - 1072

NightmareTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 13745    Accepted Submission(s): 6655 Problem DescriptionIgnatius had a nightma...

2018-07-18 11:39:08 226

原创 Knight Moves HDU - 1372

Knight MovesTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 13342    Accepted Submission(s): 7803 Problem DescriptionA friend of you is ...

2018-07-18 09:58:40 129

原创 HDU - 1045 Fire Net

Fire NetTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 14399    Accepted Submission(s): 8708Problem DescriptionSuppose that we have a square ci...

2018-07-14 16:18:56 123

原创 HDU - 1253 胜利大逃亡

胜利大逃亡Time Limit: 4000/2000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 42947    Accepted Submission(s): 14913Problem DescriptionIgnatius被魔王抓走了,有一天魔王出差去了,这可是Ignati...

2018-07-14 11:21:18 118

原创 下沙小面的(2) HDU - 1572

下沙小面的(2)Time Limit: 1000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2555    Accepted Submission(s): 1118Problem Description前文再续,书接上一题。话说当上小面的司机的Lele在施行他的那一套...

2018-07-14 10:21:42 127

原创 Kill the monster HDU - 2616

Kill the monsterTime Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1869    Accepted Submission(s): 1268Problem DescriptionThere is a mountain near ...

2018-07-13 17:28:40 161

原创 HDU3974 Assign the task(dfs建树+线段树)

Assign the taskTime Limit: 15000/5000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 4603    Accepted Submission(s): 1849Problem DescriptionThere is a company that h...

2018-05-24 11:16:45 157

原创 51nod 1341 混合序列(矩阵快速幂)

当给定p,q,r时,我们可以定义对于给定的p,q,r,n,请计算对于p=2 q=2 r=1 n=1这组数据,所以答案是Input共1行,4个整数数p, q, r, n中间用空格分隔(1 <= p, q, r, n<=1000000000)。Output对于每一个数据,在一行中输出答案。Input示例2 2 1 1Output示例3写数学题千万不能偷懒,这道题我开始一直有点懵逼,后来我把...

2018-05-22 21:23:01 144

原创 CSU - 1895(矩阵快速幂(a+b*sqrt(x))的通用方法+找规律)

Apache is a student of CSU. There is a math class every Sunday morning, but he is a very hard man who learns late every night. Unfortunate, he was late for maths on Monday. Last week the math teacher ...

2018-05-21 17:05:53 336

原创 HDU - 4027 Can you answer these queries? (线段树,坑点太多,开方操作)

Problem DescriptionA lot of battleships of evil are arranged in a line before the battle. Our commander decides to use our secret weapon to eliminate the battleships. Each of the battleships can be ma...

2018-05-10 11:18:37 172

原创 POJ - 3264

For the daily milking, Farmer John's N cows (1 ≤ N ≤ 50,000) always line up in the same order. One day Farmer John decides to organize a game of Ultimate Frisbee with some of the cows. To keep things ...

2018-05-09 20:35:56 187

原创 ZOJ - 1610(单点更新,成段染色)

Painting some colored segments on a line, some previously painted segments may be covered by some the subsequent ones.Your task is counting the segments of different colors you can see at last.InputTh...

2018-05-09 17:06:20 348

原创 POJ - 2528 (离散化+线段树区间覆盖)

DescriptionThe citizens of Bytetown, AB, could not stand that the candidates in the mayoral election campaign have been placing their electoral posters at all places at their whim. The city council ha...

2018-05-07 19:16:02 4726 2

原创 SGU - 518 Kidnapping

Berland's Police has a serious problem. A foreign ambassador arrived to Berland with an important mission, and his daughter was kidnapped just from the Royal Palace! Inspired by adventures of Erast Fa...

2018-05-07 16:46:44 159

原创 HDU - 4452

Problem DescriptionRabbit Tom and rabbit Jerry are running in a field. The field is an N×N grid. Tom starts from the up-left cell and Jerry starts from the down-right cell. The coordinate of the up-le...

2018-05-07 09:56:39 214

原创 nyoj1129

神秘瀑布镇是一个神秘的地方,那里有吸血鬼,狼人,巫师,二重身。 Klaus(吸血鬼祖先) 为了利用 Elena 的血液发展他的混血大军(吸血鬼&狼人),也来到了神秘瀑布镇。Stefan 因为深爱着 Elena ,于是 Stefan 决定去唤醒吸血鬼猎人,来解救 Elena 。     吸血鬼猎人被封锁在一个迷宫里,这个迷宫有一种特性,只要进入就会失去方向感。于是 Stefan 想到一种方法...

2018-05-04 09:38:55 109

原创 组队赛第七场

记录一下个人认为有意义的题大鱼吃小鱼  51Nod - 1289 有N条鱼每条鱼的位置及大小均不同,他们沿着X轴游动,有的向左,有的向右。游动的速度是一样的,两条鱼相遇大鱼会吃掉小鱼。从左到右给出每条鱼的大小和游动的方向(0表示向左,1表示向右)。问足够长的时间之后,能剩下多少条鱼?Input第1行:1个数N,表示鱼的数量(1 <= N <= 100000)。 第2 - N + 1行:...

2018-05-01 20:57:45 134

原创 zoj3939(打表,基姆拉尔森计算公式,计算某天是星期几的方法)

Edward, the headmaster of the Marjar University, is very busy every day and always forgets the date.There was one day Edward suddenly found that if Monday was the 1st, 11th or 21st day of that month, ...

2018-04-30 10:58:21 277

原创 POJ3233

Matrix Power SeriesTime Limit: 3000MS Memory Limit: 131072KTotal Submissions: 26191 Accepted: 10773DescriptionGiven a n × n matrix A and a positive integer k, find the sum S = A + A2 + A3 + … + Ak.Inp...

2018-04-26 14:41:22 481 1

原创 ZOJ - 3781 Paint the Grid Reloaded (dfs建图,bfs找最长路中的最小值)

Leo has a grid with N rows and M columns. All cells are painted with either black or white initially.Two cells A and B are called connected if they share an edge and they are in the same color, or the...

2018-04-25 17:21:12 241

原创 SPOJ - VECTAR1 Matrices with XOR property

Imagine A is a NxM matrix with two basic properties1) Each element in the matrix is distinct and lies in the range of 1<=A[i][j]<=(N*M)2) For any two cells of the matrix, (i1,j1) and (i2,j2), if...

2018-04-20 11:29:03 129

原创 CodeForces - 546D Soldier and Number Game(素数筛法打表前缀和)

outputstandard outputTwo soldiers are playing a game. At the beginning first of them chooses a positive integer n and gives it to the second soldier. Then the second one tries to make maximum possible...

2018-04-20 08:36:44 235

转载 HDU - 5858(acos返回的是弧度)

Problem Descriptioncjj is fun with math problem. One day he found a Olympic Mathematics problem for primary school students. It is too difficult for cjj. Can you solve it?Give you the side length of t...

2018-04-19 21:22:44 250

空空如也

空空如也

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

TA关注的人

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