2)

Codeforces Round #242 (Div. 2) B

不羁的心 提交于 2021-02-08 06:37:49
question B. Megacity time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output The administration of the Tomsk Region firmly believes that it's time to become a megacity (that is, get population of one million). Instead of improving the demographic situation, they decided to achieve its goal by expanding the boundaries of the city. The city of Tomsk can be represented as point on the plane with coordinates ( 0 ; 0 ). The city is surrounded with n other locations, the i -th one has coordinates ( x i , y i ) with the population of k i people.