随笔分类 -  HDU/POJ/BZOJ/计蒜客/ZOJ

摘要:WLD is always very lucky.His secret is a lucky number . is a fixed odd number. Now he meets a stranger with numbers:.The stranger asks him questions.E 阅读全文
posted @ 2019-08-16 21:43 茄子Min 阅读(178) 评论(0) 推荐(0)
摘要: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 阅读全文
posted @ 2019-08-16 17:13 茄子Min 阅读(223) 评论(0) 推荐(0)
摘要:2038: [2009国家集训队]小Z的袜子(hose) Time Limit: 20 Sec Memory Limit: 259 MB Submit: 19269 Solved: 8851 [Submit][Status][Discuss] Description 作为一个生活散漫的人,小Z每天早 阅读全文
posted @ 2019-08-16 17:04 茄子Min 阅读(172) 评论(0) 推荐(0)
摘要:After inventing Turing Tree, 3xian always felt boring when solving problems about intervals, because Turing Tree could easily have the solution. As we 阅读全文
posted @ 2019-08-06 21:07 茄子Min 阅读(273) 评论(0) 推荐(0)
摘要:在半径为 1 的圆上有 n 个点,它们也是圆的 n 等分点,将每个相邻的 n 等分点相连,组成了一个正 n边形,现在你可以在圆上再增加一个点,使得新的 n + 1 边形的面积最大,请输出最大面积。 Input 输入有多组(不超过 100 组)。 每组数据一行一个整数 n 代表点的数量。 3 ≤ n 阅读全文
posted @ 2019-08-06 14:11 茄子Min 阅读(299) 评论(0) 推荐(0)
摘要:wls 有三棵树,树上每个节点都有一个值 ai,现在有 2 种操作: 1. 将一条链上的所有节点的值开根号向下取整; 2. 求一条链上值的和; 链的定义是两点之间的最短路。 Input 第一行两个数 n, q 分别代表树上点的数量和操作数量。 第二行 n 个整数,第 i 个数代表第 i 个点的值 a 阅读全文
posted @ 2019-08-06 01:50 茄子Min 阅读(466) 评论(0) 推荐(0)
摘要:A 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. Ea 阅读全文
posted @ 2019-08-06 01:01 茄子Min 阅读(328) 评论(0) 推荐(0)
摘要:wls 有 n 个二次函数 Fi(x) = aix2 + bix + ci (1 ≤ i ≤ n). 现在他想在∑ni=1xi = m 且 x 为正整数的条件下求∑ni=1Fi(xi)的最小值。 请求出这个最小值。 Input 第一行两个正整数 n, m。 下面 n 行,每行三个整数 a, b, c 阅读全文
posted @ 2019-08-05 23:20 茄子Min 阅读(356) 评论(0) 推荐(0)
摘要:Recently, Shua Shua had a big quarrel with his GF. He is so upset that he decides to take a trip to some other city to avoid meeting her. He will trav 阅读全文
posted @ 2019-08-04 17:02 茄子Min 阅读(192) 评论(0) 推荐(0)
摘要:wls 有一个整数 n,他想将 1 − n 这 n 个数字分成两组,每一组至少有一个数,并且使得两组数字的和的最大公约数最大,请输出最大的最大公约数。 Input 输入一行一个整数 n。 2 ≤ n ≤ 1, 000, 000, 000 Output 输出一行一个整数表示答案。 Sample Inp 阅读全文
posted @ 2019-08-03 01:55 茄子Min 阅读(485) 评论(0) 推荐(0)
摘要:链接:https://ac.nowcoder.com/acm/contest/993/E 来源:牛客网 对牛排序 时间限制:C/C++ 1秒,其他语言2秒 空间限制:C/C++ 32768K,其他语言65536K 64bit IO Format: %lld 题目描述 Farmer John正在尝试将 阅读全文
posted @ 2019-08-01 20:13 茄子Min 阅读(394) 评论(0) 推荐(0)
摘要:链接:https://ac.nowcoder.com/acm/contest/984/J 来源:牛客网 护城河 时间限制:C/C++ 1秒,其他语言2秒 空间限制:C/C++ 32768K,其他语言65536K 64bit IO Format: %lld 题目描述 为了防止口渴的食蚁兽进入他的农场, 阅读全文
posted @ 2019-08-01 18:17 茄子Min 阅读(167) 评论(0) 推荐(0)
摘要:链接:https://ac.nowcoder.com/acm/contest/984/L 来源:牛客网 Catch That Cow 时间限制:C/C++ 1秒,其他语言2秒 空间限制:C/C++ 32768K,其他语言65536K 64bit IO Format: %lld 题目描述 Farmer 阅读全文
posted @ 2019-07-26 21:40 茄子Min 阅读(219) 评论(0) 推荐(0)
摘要:Jim has a balance and N weights. (1≤N≤20) The balance can only tell whether things on different side are the same weight. Weights can be put on left s 阅读全文
posted @ 2019-07-19 22:16 茄子Min 阅读(213) 评论(0) 推荐(0)
摘要:Kiki likes traveling. One day she finds a magic lamp, unfortunately the genie in the lamp is not so kind. Kiki must answer a question, and then the ge 阅读全文
posted @ 2019-07-19 21:16 茄子Min 阅读(295) 评论(0) 推荐(0)
摘要:Summer again! Flynn is ready for another tour around. Since the tour would take three or more days, it is important to find a hotel that meets for a r 阅读全文
posted @ 2019-07-19 18:16 茄子Min 阅读(238) 评论(0) 推荐(0)
摘要:YaoYao has a company and he wants to employ m people recently. Since his company is so famous, there are n people coming for the interview. However, Y 阅读全文
posted @ 2019-07-19 16:41 茄子Min 阅读(332) 评论(0) 推荐(0)
摘要:链接:https://ac.nowcoder.com/acm/contest/881/B 来源:牛客网 Integration 时间限制:C/C++ 2秒,其他语言4秒 空间限制:C/C++ 524288K,其他语言1048576K 64bit IO Format: %lld 题目描述 Bobo k 阅读全文
posted @ 2019-07-18 19:43 茄子Min 阅读(325) 评论(0) 推荐(0)
摘要:哈利波特在魔法学校的必修课之一就是学习魔咒。据说魔法世界有100000种不同的魔咒,哈利很难全部记住,但是为了对抗强敌,他必须在危急时刻能够调用任何一个需要的魔咒,所以他需要你的帮助。 给你一部魔咒词典。当哈利听到一个魔咒时,你的程序必须告诉他那个魔咒的功能;当哈利需要某个功能但不知道该用什么魔咒时 阅读全文
posted @ 2019-07-17 21:03 茄子Min 阅读(367) 评论(0) 推荐(0)
摘要:Many people like to solve hard puzzles some of which may lead them to madness. One such puzzle could be finding a hidden prime number in a given text. 阅读全文
posted @ 2019-07-17 16:59 茄子Min 阅读(195) 评论(0) 推荐(0)