UVA
kewlgrl
好大一只咸鱼哇
展开
-
UVA-11000 Bee-蜜蜂繁殖
In Africa there is a very special species of bee. Every year, the female bees of such species give birthto one male bee, while the male bees give birth to one male bee and one female bee, and then t原创 2015-08-08 08:34:05 · 1170 阅读 · 0 评论 -
UVA-1068 Sum-1-N之间所有数的和
1068. SumTime limit: 2.0 secondMemory limit: 64 MBYour task is to find the sum of all integer numbers lying between 1 and N inclusive.InputThe input consists of a single integer N that is no原创 2015-08-07 19:50:52 · 774 阅读 · 0 评论 -
UVA 11235-Frequent values(RMQ)
Frequent values题目意思:给出一个非降序排列的整数数组A,对于一系列询问(L,R),求出AL~AR区间内出现次数最多的值出现的次数。解题思路:数组非降序,所以对整个数组进行游程编码。所求的最大值是以下三个部分的最大值:①从L到L所在的段的结束处的元素个数:right[L]-L+1②从R到R所在的段的开始处的元素个数:R-left[R]+1③原创 2016-08-08 17:17:19 · 554 阅读 · 0 评论 -
UVA 11729-Commando War(排序分任务)
Commando War“Waiting for orders we held in the wood, word from the front never cameBy evening the sound of the gunfire was miles awayAh softly we moved through the shadows, slip away through t原创 2016-10-28 19:58:47 · 780 阅读 · 0 评论 -
UVA 11464-Even Parity(偶数矩阵-开关问题)
11464 - Even ParityTime limit: 3.000 secondsWe have a grid of size N × N. Each cell of the grid initially contains a zero(0) or a one(1). The parityof a cell is the number of 1s surrounding th原创 2016-10-19 20:05:12 · 1228 阅读 · 1 评论