B. Vanya and Lanterns time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Vanya walks late at night along a straight street of length l, lit by n lanterns. Consider the coordinate system with t…
Codeforces 492B B. Vanya and Lanterns 题目链接:http://acm.hust.edu.cn/vjudge/contest/view.action?cid=86640#problem/B 题目: Description Vanya walks late at night along a straight street of length l, lit by n lanterns. Consider the coordinate system with…
Description Vanya walks late at night along a straight street of length l, lit by n lanterns. Consider the coordinate system with the beginning of the street corresponding to the point 0, and its end corresponding to the point l. Then the i-th lanter…
A. Vanya and Cubes time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Vanya got n cubes. He decided to build a pyramid from them. Vanya wants to build the pyramid as follows: the top level of…
A. Vanya and Cubes time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Vanya got n cubes. He decided to build a pyramid from them. Vanya wants to build the pyramid as follows: the top level of…
Lanterns 题目链接:http://acm.hust.edu.cn/vjudge/contest/view.action?cid=86640#problem/B 题目: Description Vanya walks late at night along a straight street of length l, lit by n lanterns. Consider the coordinate system with the beginning of the street corr…
C. Vanya and Scales Vanya has a scales for weighing loads and weights of masses w0, w1, w2, ..., w100 grams where w is some integer not less than 2(exactly one weight of each nominal value). Vanya wonders whether he can weight an item with mass m usi…