
思维
文章平均质量分 81
Apoised
我将一直前行,即使那时身边空无一人。
展开
-
思维 hdu 5100 (chessboard)
思维原创 2016-08-16 17:06:57 · 291 阅读 · 0 评论 -
思维 lcs lightoj1033(Generating Palindromes)
Generating PalindromesTime Limit: 2 second(s)Memory Limit: 32 MBBy definition palindrome is a string which is not changed when reversed. "MADAM" is a nice example of palind原创 2016-09-27 11:25:04 · 250 阅读 · 0 评论 -
组合数学 poj 1942(Paths on a Grid)
Paths on a GridDescriptionImagine you are attending your math lesson at school. Once again, you are bored because your teacher tells things that you already mastered years ago (this time he's ex原创 2016-10-12 18:21:42 · 454 阅读 · 0 评论 -
思维 hdu 1847 (Good Luck in CET-4 Everybody!)
Good Luck in CET-4 EverybodyProblem Description大学英语四级考试就要来临了,你是不是在紧张的复习?也许紧张得连短学期的ACM都没工夫练习了,反正我知道的Kiki和Cici都是如此。当然,作为在考场浸润了十几载的当代大学生,Kiki和Cici更懂得考前的放松,所谓“张弛有道”就是这个意思。这不,Kiki和Cici在每天晚上休息之前都要原创 2016-10-12 18:07:00 · 218 阅读 · 0 评论 -
思维 hdu 5904 (LCIS)
LCISProblem DescriptionAlex has two sequences a1,a2,...,an and b1,b2,...,bm. He wants find a longest common subsequence that consists of consecutive values in increasing order.原创 2016-09-25 16:52:19 · 299 阅读 · 0 评论 -
无向图最小环 hdu1599 (find the mincost route)
find the mincost route Problem Description杭州有N个景区,景区之间有一些双向的路来连接,现在8600想找一条旅游路线,这个路线从A点出发并且最后回到A点,假设经过的路线为V1,V2,....VK,V1,那么必须满足K>2,就是说至除了出发点以外至少要经过2个其他不同的景区,而且不能重复经过同一个景区。现在8600需要你帮他找一条这样的路线,并且原创 2016-08-24 20:52:28 · 292 阅读 · 0 评论 -
hdu 5587 (Array)
ArrayDescriptionVicky is a magician who loves math. She has great power in copying and creating. One day she gets an array {1}。 After that, every day she copies all the numbers in the ar原创 2016-08-24 11:53:54 · 450 阅读 · 0 评论 -
Lightoj 1045 (Digits of factoria)
数学 Digits of factoriaDescriptionFactorial of an integer is defined by the following functionf(0) = 1f(n) = f(n - 1) * n, if(n > 0)So, factorial of 5 is 120. But in different bases, the原创 2016-08-24 09:33:49 · 253 阅读 · 0 评论 -
Lightoj 1282 (Leading and Trailing)
Leading and TrailingDescriptionYou are given two integers: n and k, your task is to find the most significant three digits, and least significant three digits of nk.InputInput st原创 2016-08-23 21:26:03 · 337 阅读 · 0 评论 -
思维 hdu 5247 (找连续数)
找连续数 Problem Description小度熊拿到了一个无序的数组,对于这个数组,小度熊想知道是否能找到一个k 的区间,里面的 k 个数字排完序后是连续的。现在小度熊增加题目难度,他不想知道是否有这样的 k 的区间,而是想知道有几个这样的 k 的区间。 Input输入包含一组测试数据。第一行包含两个整数n,m,n代表数组中有多少个数字,m 代原创 2016-08-23 11:01:13 · 591 阅读 · 0 评论 -
zzuli 1902 (985的因子对难题)
打表 985的因子对难题Description985有n个正整数,他想知道存在多少个不同的因子对(a[i], a[j])使得1 特别地,他认为(a[i],a[j])与(a[j],a[i])是一样的因子对。Input第一行输入一个整数t,代表有t组测试数据。每组数据占两行,第一行输入一个n代表元素个数,下面一行输入n个整数a[]。注:1原创 2016-08-10 09:49:14 · 212 阅读 · 0 评论 -
zzuli 1916 (晴天 树 )
dfs+树状数组 原题 Description给一颗树,有n个结点,编号为1到n,1为根节点,有两种操作,1 x y把x结点权值加y,2 x查询x到根节点所有结点的权值和.每个结点权值初始化为0。Input第一行输入一个整数t,代表有t组测试数据。每组数据第一行为两个整数n,m代表结点个数和操作次数。接下来n-1行,每行两原创 2016-08-19 20:19:43 · 264 阅读 · 0 评论 -
zzuli 1917(晴天子序列)
原题 二分+vectorDescription晴天有非常严重的选择恐惧症,每次吃饭前他都在纠结到底吃什么。。今天又到了吃饭的时候了。重光:我给你一个包含n个不同整数的序列a,如果它所有连续子序列的价值和是素数咱们就吃米,不然就吃面。定义一个序列的价值为序列中所有元素的最小值。晴天:这不是分分钟给你算出来。嗯...十分钟过去了,晴天选择死亡。这个任务就交给你啦。原创 2016-08-19 15:59:58 · 438 阅读 · 0 评论 -
思维 hdu 5512(Pagodas)
PagodasDescription pagodas were standing erect in Hong Jue Si between the Niushou Mountain and the Yuntai Mountain, labelled from to . However, only two of them (labelled and , whe原创 2016-08-16 20:14:20 · 350 阅读 · 0 评论 -
lightoj 1410 - Consistent Verdicts1410 - Consistent Verdicts
去重1410 - Consistent VerdictsIn a 2D plane N persons are standing and each of them has a gun in his hand. The plane is so big that the persons can be considered as points and their locations ar原创 2016-11-04 17:07:48 · 271 阅读 · 0 评论