zhber
有好多做过的题没写下来,如果我还能记得就补吧
07 2017 档案
cf21D Traveling Graph
摘要:You are given undirected weighted graph. Find the length of the shortest cycle which starts from the vertex 1 and passes throught all the edges at lea 阅读全文
posted @ 2017-07-24 16:53 zhber 阅读(354) 评论(0) 推荐(0)
Spoj-ODDDIV Odd Numbers of Divisors
摘要:Given a positive odd integer K and two positive integers low and high, determine how many integers between low and high contain exactly K divisors. In 阅读全文
posted @ 2017-07-24 16:43 zhber 阅读(326) 评论(0) 推荐(0)
cf3D Least Cost Bracket Sequence
摘要:This is yet another problem on regular bracket sequences. A bracket sequence is called regular, if by inserting "+" and "1" into it we get a correct m 阅读全文
posted @ 2017-07-24 16:31 zhber 阅读(352) 评论(0) 推荐(0)
Spoj-FACVSPOW Factorial vs Power
摘要:Consider two integer sequences f(n) = n! and g(n) = an, where n is a positive integer. For any integer a > 1 the second sequence is greater than the f 阅读全文
posted @ 2017-07-24 11:27 zhber 阅读(264) 评论(0) 推荐(0)
数学简直不及格
摘要:再忘记怎么维护上凸壳我就把zhber改成rebhz 两向量α=(x1,y1),β=(x2,y2) α x β = |α| x |β| x sinθ=x1y2-x2y1 α x β = 0,两向量共线但是不一定同向 α x β < 0,α在β的顺时针方向(左边) α x β > 0,α在β的逆时针方向 阅读全文
posted @ 2017-07-17 20:06 zhber
cf670E Correct Bracket Sequence Editor
摘要:Recently Polycarp started to develop a text editor that works only with correct bracket sequences (abbreviated as CBS). Note that a bracket sequence i 阅读全文
posted @ 2017-07-15 12:43 zhber 阅读(322) 评论(0) 推荐(0)
hdu3038 How Many Answers Are Wrong
摘要:TT and FF are ... friends. Uh... very very good friends -________-b FF is a bad boy, he is always wooing TT to play the following game with him. This 阅读全文
posted @ 2017-07-15 12:27 zhber 阅读(158) 评论(0) 推荐(0)
Spoj-BGSHOOT
摘要:The problem is about Mr.BG who is a great hunter. Today he has gone to a dense forest for hunting and killing animals. Sadly, he has only one bullet i 阅读全文
posted @ 2017-07-15 12:26 zhber 阅读(160) 评论(0) 推荐(0)
Spoj-ANTP Mr. Ant & His Problem
摘要:Mr. Ant has 3 boxes and the infinite number of marbles. Now he wants to know the number of ways he can put marbles in these three boxes when the follo 阅读全文
posted @ 2017-07-15 12:19 zhber 阅读(213) 评论(0) 推荐(0)
Spoj-BIPCSMR16 Team Building
摘要:To make competitive programmers of BUBT, authority decide to take regular programming contest. To make this contest more competitive and fruitful ther 阅读全文
posted @ 2017-07-15 12:07 zhber 阅读(303) 评论(0) 推荐(0)
cf575A Fibonotci
摘要:Fibonotci sequence is an integer recursive sequence defined by the recurrence relation Fn = sn - 1·Fn - 1 + sn - 2·Fn - 2withF0 = 0, F1 = 1 Sequence s 阅读全文
posted @ 2017-07-14 22:13 zhber 阅读(820) 评论(0) 推荐(0)
cf660E Different Subsets For All Tuples
摘要:For a sequence a of n integers between 1 and m, inclusive, denote f(a) as the number of distinct subsequences of a (including the empty subsequence). 阅读全文
posted @ 2017-07-14 19:34 zhber 阅读(274) 评论(0) 推荐(0)
cf468C Hack it!
摘要:Little X has met the following problem recently. Let's define f(x) as the sum of digits in decimal representation of number x (for example, f(1234) =  阅读全文
posted @ 2017-07-14 00:14 zhber 阅读(431) 评论(0) 推荐(0)
cf468B Two Sets
摘要:Little X has n distinct integers: p1, p2, ..., pn. He wants to divide all of them into two sets A and B. The following two conditions must be satisfie 阅读全文
posted @ 2017-07-13 23:56 zhber 阅读(338) 评论(0) 推荐(0)
cf701E Connecting Universities
摘要:Treeland is a country in which there are n towns connected by n - 1 two-way road such that it's possible to get from any town to any other town. In Tr 阅读全文
posted @ 2017-07-13 23:26 zhber 阅读(238) 评论(0) 推荐(0)
cf441E Valera and Number
只有注册用户登录后才能阅读该文。
posted @ 2017-07-13 22:48 zhber 阅读(13) 评论(0) 推荐(0)
Spoj-BLMIRINA Archery Training
摘要:Mirana is an archer with superpower. Every arrow she shoots will get stronger the further it travels. Mirana is currently on the way to warzone. Since 阅读全文
posted @ 2017-07-12 00:38 zhber 阅读(160) 评论(0) 推荐(0)
Spoj-BITDIFF Bit Difference
摘要:Given an integer array of N integers, find the sum of bit differences in all the pairs that can be formed from array elements. Bit difference of a pai 阅读全文
posted @ 2017-07-12 00:25 zhber 阅读(180) 评论(0) 推荐(0)
Spoj-VISIBLEBOX Decreasing Number of Visible Box
摘要:Shadowman loves to collect box but his roommates woogieman and itman don't like box and so shadowman wants to hide boxes as many as possible. A box ca 阅读全文
posted @ 2017-07-12 00:20 zhber 阅读(228) 评论(0) 推荐(0)
cf615D Multipliers
摘要:Ayrat has number n, represented as it's prime factorization pi of size m, i.e. n = p1·p2·...·pm. Ayrat got secret information that that the product of 阅读全文
posted @ 2017-07-12 00:11 zhber 阅读(790) 评论(0) 推荐(0)
Spoj-NPC2015A Eefun Guessing Words
摘要:Eefun Guessing Words Eefun is currently learning to read. His way of learning is unique, by trying to make every possible substring from a given strin 阅读全文
posted @ 2017-07-11 23:29 zhber 阅读(236) 评论(0) 推荐(0)
Spoj-BOKAM143SOU Checking cubes.
摘要:Given a integer N. Find number of possible ways to represent N as a sum of at most five cubes. Input First line contains N. 1<=N<=125000. Output Outpu 阅读全文
posted @ 2017-07-11 23:26 zhber 阅读(174) 评论(0) 推荐(0)
cf682E Alyona and Triangles
摘要:You are given n points with integer coordinates on the plane. Points are given in a way such that there is no triangle, formed by any three of these n 阅读全文
posted @ 2017-07-11 23:23 zhber 阅读(1558) 评论(0) 推荐(0)
cf487C Prefix Product Sequence
摘要:Consider a sequence [a1, a2, ... , an]. Define its prefix product sequence . Now given n, find a permutation of [1, 2, ..., n], such that its prefix p 阅读全文
posted @ 2017-07-11 23:12 zhber 阅读(246) 评论(0) 推荐(0)
cf299C Weird Game
摘要:Weird Game Yaroslav, Andrey and Roman can play cubes for hours and hours. But the game is for three, so when Roman doesn't show up, Yaroslav and Andre 阅读全文
posted @ 2017-07-11 22:45 zhber 阅读(355) 评论(0) 推荐(0)
cf550D Regular Bridge
摘要:Regular Bridge An undirected graph is called k-regular, if the degrees of all its vertices are equal k. An edge of a connected graph is called a bridg 阅读全文
posted @ 2017-07-11 22:40 zhber 阅读(239) 评论(0) 推荐(0)
Spoj-TRNGL Make Triangle
摘要:Make Triangle Chayanika loves Mathematics. She is learning a new chapter geometry. While reading the chapter a question came in her mind. Given a conv 阅读全文
posted @ 2017-07-11 22:26 zhber 阅读(261) 评论(0) 推荐(0)
Spoj-DWARFLOG Manipulate Dwarfs
摘要:Manipulate Dwarfs In a small village beyond seven hills and seven seas, Snow White lives together with N dwarves who spend all their time eating and p 阅读全文
posted @ 2017-07-11 22:21 zhber 阅读(245) 评论(0) 推荐(0)
Spoj-DRUIDEOI Fata7y Ya Warda!
摘要:Fata7y Ya Warda! Druid (AKA Amr Alaa El-Deen) and little EOIers have finished their training and they are playing "Fatta7y ya warda!". It's a kids gam 阅读全文
posted @ 2017-07-11 22:15 zhber 阅读(177) 评论(0) 推荐(0)
LightOJ1106 Gone Fishing
摘要:Gone Fishing John is going on a fishing trip. He has h hours available, and there are n lakes in the area all reachable along a single, one-way road. 阅读全文
posted @ 2017-07-11 22:10 zhber 阅读(176) 评论(0) 推荐(0)
LightOJ1125 Divisible Group Sums
摘要:Divisible Group Sums Given a list of N numbers you will be allowed to choose any M of them. So you can choose in NCM ways. You will have to determine 阅读全文
posted @ 2017-07-11 21:32 zhber 阅读(134) 评论(0) 推荐(0)
hdu5396 Expression
摘要:Expression Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 952 Accepted Submission(s): 573 Proble 阅读全文
posted @ 2017-07-11 21:24 zhber 阅读(201) 评论(0) 推荐(0)
cf715B Complete The Graph
摘要:B. Complete The Graph time limit per test 4 seconds memory limit per test 256 megabytes input standard input output standard output B. Complete The Gr 阅读全文
posted @ 2017-07-11 21:07 zhber 阅读(1391) 评论(0) 推荐(0)