摘要: Every year the cows hold an event featuring a peculiar version of hopscotch that involves carefully jumping from rock to rock in a river. The exciteme 阅读全文
posted @ 2017-04-29 00:12 天之道,利而不害 阅读(180) 评论(0) 推荐(0) 编辑
摘要: It is very hard to wash and especially to dry clothes in winter. But Jane is a very smart girl. She is not afraid of this boring process. Jane has dec 阅读全文
posted @ 2017-04-26 17:23 天之道,利而不害 阅读(262) 评论(0) 推荐(0) 编辑
摘要: Given N numbers, X1, X2, ... , XN, let us calculate the difference of every pair of numbers: ∣Xi - Xj∣ (1 ≤ i < j ≤ N). We can get C(N,2) differences 阅读全文
posted @ 2017-04-25 22:49 天之道,利而不害 阅读(198) 评论(0) 推荐(0) 编辑
摘要: Farmer John is an astounding accounting wizard and has realized he might run out of money to run the farm. He has already calculated and recorded the 阅读全文
posted @ 2017-04-23 21:49 天之道,利而不害 阅读(223) 评论(0) 推荐(0) 编辑
摘要: King George has recently decided that he would like to have a new design for the royal graveyard. The graveyard must consist of several sections, each 阅读全文
posted @ 2017-04-23 21:43 天之道,利而不害 阅读(352) 评论(0) 推荐(0) 编辑
摘要: Some positive integers can be represented by a sum of one or more consecutive prime numbers. How many such representations does a given positive integ 阅读全文
posted @ 2017-04-23 21:38 天之道,利而不害 阅读(282) 评论(1) 推荐(0) 编辑
摘要: As you very well know, this year's funkiest numbers are so called triangular numbers (that is, integers that are representable as , where k is some po 阅读全文
posted @ 2017-04-23 12:05 天之道,利而不害 阅读(546) 评论(0) 推荐(0) 编辑
摘要: One day a highly important task was commissioned to Vasya — writing a program in a night. The program consists of n lines of code. Vasya is already ex 阅读全文
posted @ 2017-04-23 12:01 天之道,利而不害 阅读(344) 评论(0) 推荐(0) 编辑
摘要: This problem is given in two versions that differ only by constraints. If you can solve this problem in large constraints, then you can just write a s 阅读全文
posted @ 2017-04-22 16:09 天之道,利而不害 阅读(321) 评论(0) 推荐(0) 编辑
摘要: Kefa wants to celebrate his first big salary by going to restaurant. However, he needs company. Kefa has n friends, each friend will agree to go to th 阅读全文
posted @ 2017-04-21 23:39 天之道,利而不害 阅读(325) 评论(0) 推荐(0) 编辑