Codeforces Round 278 (Div. 1)

Solutions are presented as using the least memory and the fastest execution time. It also takes the top 10 most recent solutions from each language. If you want to limit to a specific index, click the "Solved" button and go to that problem.

ContestId
Name
Phase
Frozen
Duration (Seconds)
Relative Time
Start Time
487 Codeforces Round 278 (Div. 1) FINISHED False 7200 315232799 Nov. 21, 2014, 5:20 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 3772 ) A Fight the Monster PROGRAMMING binary search brute force implementation 1900

B"A monster is attacking the Cyberland! Master Yang, a braver, is going to beat the monster. Yang and the monster each have 3 attributes: hitpoints (HP), offensive power (ATK) and defensive power (DEF). During the battle, every second the monster's HP decrease by max(0, xe2 x80 x89ATKY xe2 x80 x89- xe2 x80 x89DEFM), while Yang's HP decreases by max(0, xe2 x80 x89ATKM xe2 x80 x89- xe2 x80 x89DEFY), where index Y denotes Master Yang and index M denotes monster. Both decreases happen simultaneously Once monster's HP xe2 x80 x89 xe2 x89 xa4 xe2 x80 x890 and the same time Master Yang's HP xe2 x80 x89> xe2 x80 x890, Master Yang wins. Master Yang can buy attributes from the magic shop of Cyberland: h bitcoins per HP, a bitcoins per ATK, and d bitcoins per DEF. Now Master Yang wants to know the minimum number of bitcoins he can spend in order to win. The first line contains three integers HPY, xe2 x80 x89ATKY, xe2 x80 x89DEFY, separated by a space, denoting the initial HP, ATK and DEF of Master Yang. The second line contains three integers HPM, xe2 x80 x89ATKM, xe2 x80 x89DEFM, separated by a space, denoting the HP, ATK and DEF of the monster. The third line contains three integers h, xe2 x80 x89a, xe2 x80 x89d, separated by a space, denoting the price of 1 HP, 1 ATK and 1 DEF. All numbers in input are integer and lie between 1 and 100 inclusively. The only output line should contain an integer, denoting the minimum bitcoins Master Yang should spend in order to win. For the first sample, prices for ATK and DEF are extremely high. Master Yang can buy 99 HP, then he can beat the monster with 1 HP left. For the second sample, Master Yang is strong enough to beat the monster, so he doesn't need to buy anything."...

Tutorials

Tutorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
8783475 Gassa A Nov. 21, 2014, 6:12 p.m. OK D TESTS 46 31 1024000 1900
8781183 hos.lyric A Nov. 21, 2014, 5:51 p.m. OK D TESTS 46 77 0 1900
8973852 AHTuTTuTyX A Dec. 3, 2014, 8:20 p.m. OK Delphi TESTS 46 31 102400 1900
8788444 TheHedgehog A Nov. 21, 2014, 7:03 p.m. OK Delphi TESTS 46 46 15155200 1900
8798775 MrJigan1488 A Nov. 22, 2014, 11:12 a.m. OK Delphi TESTS 46 202 31027200 1900
8906259 metalopocalipsis A Dec. 1, 2014, 4:06 p.m. OK Delphi TESTS 46 249 102400 1900
8841575 graceoflives A Nov. 25, 2014, 2:20 a.m. OK FPC TESTS 46 15 0 1900
8894939 phankhai A Nov. 30, 2014, 2:10 a.m. OK FPC TESTS 46 15 102400 1900
8826019 con_nha_nguoi_ta A Nov. 23, 2014, 3:40 p.m. OK FPC TESTS 46 15 102400 1900
8802330 seek A Nov. 22, 2014, 1:31 p.m. OK FPC TESTS 46 15 102400 1900
9154348 Freedom A Dec. 16, 2014, 5:31 p.m. OK FPC TESTS 46 30 102400 1900
8982544 anh2012thangvn A Dec. 4, 2014, 2:52 p.m. OK FPC TESTS 46 31 0 1900
51997863 luogu_bot4 A March 30, 2019, 4 a.m. OK FPC TESTS 46 31 102400 1900
8847590 huynhngocminh A Nov. 25, 2014, 3:11 p.m. OK FPC TESTS 46 31 102400 1900
8861276 BenderRodriguez A Nov. 26, 2014, 3:32 p.m. OK FPC TESTS 46 46 102400 1900
8779526 Alex_2oo8 A Nov. 21, 2014, 5:38 p.m. OK FPC TESTS 46 62 102400 1900
8792643 merolish A Nov. 21, 2014, 9:24 p.m. OK GNU C TESTS 46 31 0 1900
8786666 Thgx A Nov. 21, 2014, 6:47 p.m. OK GNU C TESTS 46 31 0 1900
8780650 zeosutt A Nov. 21, 2014, 5:46 p.m. OK GNU C TESTS 46 31 0 1900
9401276 vjudge5 A Jan. 11, 2015, 6:33 a.m. OK GNU C TESTS 46 78 0 1900
9351121 vjudge2 A Jan. 3, 2015, 8:59 a.m. OK GNU C TESTS 46 155 0 1900
27617912 ayushrai09 A June 6, 2017, 4:12 p.m. OK GNU C TESTS 46 483 36044800 1900
27617884 ayushrai09 A June 6, 2017, 4:11 p.m. OK GNU C TESTS 46 483 36044800 1900
31978401 gopal007 A Nov. 2, 2017, 11:50 a.m. OK GNU C++ TESTS 46 15 0 1900
30960872 ea6102 A Oct. 3, 2017, 7:29 a.m. OK GNU C++ TESTS 46 15 0 1900
27071457 jvj_iit A May 13, 2017, 8:31 a.m. OK GNU C++ TESTS 46 15 0 1900
26833265 begv A May 4, 2017, 11:43 a.m. OK GNU C++ TESTS 46 15 0 1900
23037998 axelabhi A Dec. 17, 2016, 2:03 a.m. OK GNU C++ TESTS 46 15 0 1900
22849760 uvsankar A Dec. 10, 2016, 7:05 a.m. OK GNU C++ TESTS 46 15 0 1900
22727580 zhan8855 A Dec. 6, 2016, 10:16 a.m. OK GNU C++ TESTS 46 15 0 1900
22118928 sanngu A Nov. 8, 2016, 6:39 p.m. OK GNU C++ TESTS 46 15 0 1900
19465955 Iskalibur A July 28, 2016, 5:35 p.m. OK GNU C++ TESTS 46 15 0 1900
18903456 misir_ali A July 5, 2016, 3:25 p.m. OK GNU C++ TESTS 46 15 0 1900
8847803 krismaz A Nov. 25, 2014, 3:35 p.m. OK GNU C++0x TESTS 46 15 0 1900
9611540 heyihong A Jan. 29, 2015, 6:43 a.m. OK GNU C++0x TESTS 46 15 0 1900
9389639 itytwt A Jan. 9, 2015, 1:33 a.m. OK GNU C++0x TESTS 46 15 0 1900
9350459 takaramono A Jan. 3, 2015, 7:08 a.m. OK GNU C++0x TESTS 46 15 0 1900
9056074 shobe A Dec. 9, 2014, 7:31 a.m. OK GNU C++0x TESTS 46 15 0 1900
8993605 Al3ks1002 A Dec. 5, 2014, 5:16 p.m. OK GNU C++0x TESTS 46 15 0 1900
8980721 mruxim A Dec. 4, 2014, noon OK GNU C++0x TESTS 46 15 0 1900
8976383 Bobgy A Dec. 4, 2014, 4:09 a.m. OK GNU C++0x TESTS 46 15 0 1900
8898964 prep A Nov. 30, 2014, 3:11 p.m. OK GNU C++0x TESTS 46 15 0 1900
8835515 Jetman A Nov. 24, 2014, 12:34 p.m. OK GNU C++0x TESTS 46 15 0 1900
57816890 rainboy A July 26, 2019, 8:13 p.m. OK GNU C11 TESTS 46 31 0 1900
29866746 rhinzler A Aug. 29, 2017, 1:16 p.m. OK GNU C++11 TESTS 46 15 0 1900
27697696 cephian A June 9, 2017, 11:41 p.m. OK GNU C++11 TESTS 46 15 0 1900
27697646 cephian A June 9, 2017, 11:31 p.m. OK GNU C++11 TESTS 46 15 0 1900
27459680 UtopiaBeam A May 31, 2017, 5:35 a.m. OK GNU C++11 TESTS 46 15 0 1900
27415006 __timus A May 28, 2017, 2:36 p.m. OK GNU C++11 TESTS 46 15 0 1900
27414613 __timus A May 28, 2017, 2:14 p.m. OK GNU C++11 TESTS 46 15 0 1900
27118808 yanQval A May 15, 2017, 9:45 a.m. OK GNU C++11 TESTS 46 15 0 1900
22890861 atulhjp A Dec. 11, 2016, 5:53 p.m. OK GNU C++11 TESTS 46 15 0 1900
22850289 bhuvi96 A Dec. 10, 2016, 7:49 a.m. OK GNU C++11 TESTS 46 15 0 1900
30947300 harpreet221295 A Oct. 2, 2017, 3:47 p.m. OK GNU C++11 TESTS 46 15 0 1900
58660737 Linkus A Aug. 12, 2019, 10:49 a.m. OK GNU C++14 TESTS 46 15 0 1900
55575558 AyaBenSaad A June 14, 2019, 11:55 p.m. OK GNU C++14 TESTS 46 15 0 1900
53494179 matumbaman A April 29, 2019, 10:45 a.m. OK GNU C++14 TESTS 46 15 0 1900
49117437 lokpati A Jan. 28, 2019, 5:35 p.m. OK GNU C++14 TESTS 46 15 0 1900
44556540 GuillermoFrancella A Oct. 19, 2018, 5:34 p.m. OK GNU C++14 TESTS 46 15 0 1900
32364509 GLAYS A Nov. 16, 2017, 8:03 p.m. OK GNU C++14 TESTS 46 15 0 1900
32227876 _comfortably_numb A Nov. 11, 2017, 6:26 p.m. OK GNU C++14 TESTS 46 15 0 1900
32114652 ujjwal9895 A Nov. 7, 2017, 10:15 a.m. OK GNU C++14 TESTS 46 15 0 1900
31172976 mochow A Oct. 9, 2017, 4:37 p.m. OK GNU C++14 TESTS 46 15 0 1900
55687757 gsaivishal A June 17, 2019, 4:24 p.m. OK GNU C++14 TESTS 46 15 0 1900
54345368 heno239 A May 18, 2019, 12:10 p.m. OK GNU C++17 TESTS 46 15 0 1900
54431241 spop A May 20, 2019, 11:39 p.m. OK GNU C++17 TESTS 46 15 0 1900
35453393 3agwa A Feb. 18, 2018, 5:49 p.m. OK GNU C++17 TESTS 46 15 1945600 1900
56006805 Ahmed_Araby A June 24, 2019, 3:58 p.m. OK GNU C++17 TESTS 46 30 0 1900
67524501 GorillaKiller A Dec. 24, 2019, 1:32 p.m. OK GNU C++17 TESTS 46 30 0 1900
64610260 iWiLL__ A Nov. 10, 2019, 12:46 a.m. OK GNU C++17 TESTS 46 30 0 1900
59268644 Felerius A Aug. 22, 2019, 11:49 a.m. OK GNU C++17 TESTS 46 30 0 1900
58085520 shikhar7s A July 31, 2019, 3:25 p.m. OK GNU C++17 TESTS 46 30 0 1900
56807928 solaimanope A July 10, 2019, 2:42 p.m. OK GNU C++17 TESTS 46 30 0 1900
54536218 quake0 A May 23, 2019, 8:23 p.m. OK GNU C++17 TESTS 46 30 0 1900
8787138 Martynas A Nov. 21, 2014, 6:51 p.m. OK Go TESTS 46 62 0 1900
67782816 guzelka A Dec. 28, 2019, 11:37 a.m. OK Java 11 TESTS 46 998 204800 1900
9160112 vjudge4 A Dec. 17, 2014, 10:04 a.m. OK Java 6 TESTS 46 109 0 1900
8784377 vitruvius A Nov. 21, 2014, 6:21 p.m. OK Java 6 TESTS 46 233 102400 1900
8779241 I_dont_have_girlfriend A Nov. 21, 2014, 5:36 p.m. OK Java 7 TESTS 46 77 0 1900
13253796 xiaowuc1 A Sept. 27, 2015, 6:20 p.m. OK Java 7 TESTS 46 77 0 1900
9821974 vjudge3 A Feb. 14, 2015, 12:10 a.m. OK Java 7 TESTS 46 77 0 1900
8798159 trunghieu11 A Nov. 22, 2014, 9:58 a.m. OK Java 7 TESTS 46 78 0 1900
9157585 tohuuquan A Dec. 17, 2014, 1:54 a.m. OK Java 7 TESTS 46 78 0 1900
8780656 hiukim A Nov. 21, 2014, 5:47 p.m. OK Java 7 TESTS 46 92 0 1900
8779256 iensen A Nov. 21, 2014, 5:36 p.m. OK Java 7 TESTS 46 92 0 1900
10409873 kimox2 A March 23, 2015, 12:15 p.m. OK Java 7 TESTS 46 93 0 1900
9279824 ctunoku A Dec. 27, 2014, 12:22 a.m. OK Java 7 TESTS 46 93 0 1900
9226880 upsolving A Dec. 22, 2014, 6:22 p.m. OK Java 7 TESTS 46 93 0 1900
15444667 qwerty787788 A Jan. 19, 2016, 10:20 p.m. OK Java 8 TESTS 46 109 0 1900
11319713 pocketsuteado A May 27, 2015, 12:59 p.m. OK Java 8 TESTS 46 109 0 1900
29287874 coderbond007 A Aug. 8, 2017, 3:03 p.m. OK Java 8 TESTS 46 109 20582400 1900
28548150 adityagupta1089 A July 14, 2017, 12:26 p.m. OK Java 8 TESTS 46 109 20582400 1900
68882178 Oom A Jan. 15, 2020, 7:18 p.m. OK Java 8 TESTS 46 124 0 1900
40237901 dipankar12 A July 12, 2018, 4:15 p.m. OK Java 8 TESTS 46 124 0 1900
32099760 ShafinKhadem A Nov. 6, 2017, 3:39 p.m. OK Java 8 TESTS 46 124 0 1900
31295106 sjain281297 A Oct. 14, 2017, 8:31 a.m. OK Java 8 TESTS 46 124 0 1900
15444583 antonkov A Jan. 19, 2016, 10:09 p.m. OK Java 8 TESTS 46 124 0 1900
11372960 Pimpom A June 1, 2015, 2:45 a.m. OK Java 8 TESTS 46 124 0 1900
8790319 kuuso A Nov. 21, 2014, 7:18 p.m. OK Mono C# TESTS 46 545 204800 1900
14806829 og.kostya A Dec. 14, 2015, 6:27 p.m. OK MS C# TESTS 46 62 102400 1900
8779738 camypaper A Nov. 21, 2014, 5:39 p.m. OK MS C# TESTS 46 62 204800 1900
8778165 azukun A Nov. 21, 2014, 5:30 p.m. OK MS C# TESTS 46 62 512000 1900
8803263 Yuliy A Nov. 22, 2014, 2:49 p.m. OK MS C++ TESTS 46 15 0 1900
16418045 nigimi A Feb. 28, 2016, 10:18 p.m. OK MS C++ TESTS 46 15 0 1900
15628508 xieofxie A Jan. 28, 2016, 12:17 p.m. OK MS C++ TESTS 46 15 0 1900
12822694 915507430 A Sept. 3, 2015, 2:21 a.m. OK MS C++ TESTS 46 15 0 1900
12127082 Vtz A July 20, 2015, 8:39 a.m. OK MS C++ TESTS 46 15 0 1900
11516868 honestman A June 10, 2015, 4:29 a.m. OK MS C++ TESTS 46 15 0 1900
9244002 Darek_ A Dec. 24, 2014, 1:30 p.m. OK MS C++ TESTS 46 15 0 1900
9008486 r13 A Dec. 7, 2014, 10:43 a.m. OK MS C++ TESTS 46 15 0 1900
8797810 Tinsane A Nov. 22, 2014, 9:18 a.m. OK MS C++ TESTS 46 15 0 1900
8795248 rotoZOOM A Nov. 22, 2014, 4:17 a.m. OK MS C++ TESTS 46 15 0 1900
59563691 CtrlAlt A Aug. 27, 2019, 9:45 a.m. OK MS C++ 2017 TESTS 46 77 0 1900
21659523 Yash_ A Oct. 22, 2016, 7:02 a.m. OK PyPy 2 TESTS 46 109 409600 1900
67370473 ashok123 A Dec. 21, 2019, 1:57 p.m. OK PyPy 2 TESTS 46 139 716800 1900
45085014 homoeconomicus A Oct. 30, 2018, 6:44 a.m. OK PyPy 3 TESTS 46 186 921600 1900
35875344 ______u______ A March 3, 2018, 8:15 a.m. OK PyPy 3 TESTS 46 373 20787200 1900
35875195 ______n______ A March 3, 2018, 8:09 a.m. OK PyPy 3 TESTS 46 373 20787200 1900
35874668 _____k_____ A March 3, 2018, 7:57 a.m. OK PyPy 3 TESTS 46 373 20787200 1900
35874528 _____i_____ A March 3, 2018, 7:53 a.m. OK PyPy 3 TESTS 46 373 20787200 1900
35871213 ______h______ A March 3, 2018, 6:46 a.m. OK PyPy 3 TESTS 46 373 20787200 1900
35871181 ______k______ A March 3, 2018, 6:46 a.m. OK PyPy 3 TESTS 46 373 20787200 1900
35870424 ______i______ A March 3, 2018, 6:28 a.m. OK PyPy 3 TESTS 46 373 20787200 1900
35863387 ______M______ A March 2, 2018, 10:45 p.m. OK PyPy 3 TESTS 46 373 20787200 1900
9148413 Chiba A Dec. 16, 2014, 6:14 a.m. OK Python 2 TESTS 46 62 0 1900
8792544 nwi A Nov. 21, 2014, 9:16 p.m. OK Python 2 TESTS 46 62 0 1900
10302539 nealzane A March 16, 2015, 5:23 p.m. OK Python 2 TESTS 46 77 0 1900
9796199 gnldkm A Feb. 11, 2015, 7:53 a.m. OK Python 2 TESTS 46 77 0 1900
16639597 viralm A March 10, 2016, 8:23 p.m. OK Python 2 TESTS 46 187 0 1900
34573312 pavankatta A Jan. 26, 2018, 11:11 a.m. OK Python 2 TESTS 46 202 4608000 1900
15914480 not_bot_but_POT A Feb. 9, 2016, 1:45 p.m. OK Python 3 TESTS 46 62 0 1900
9551178 yugle7 A Jan. 25, 2015, 4:05 p.m. OK Python 3 TESTS 46 62 0 1900
8803704 tomlau A Nov. 22, 2014, 3:24 p.m. OK Python 3 TESTS 46 62 0 1900
8804075 tomlau A Nov. 22, 2014, 3:54 p.m. OK Python 3 TESTS 46 77 0 1900
49774487 nethish A Feb. 11, 2019, 2:54 p.m. OK Python 3 TESTS 46 124 0 1900
42005706 Mk_Python_v1 A Aug. 23, 2018, 6:17 p.m. OK Python 3 TESTS 46 124 0 1900
37536969 nowyyz A April 22, 2018, 4:40 p.m. OK Python 3 TESTS 46 124 7065600 1900
15441049 newbeginBKB A Jan. 19, 2016, 1:56 p.m. OK Python 3 TESTS 46 139 0 1900
49961536 __Melodies A Feb. 15, 2019, 6:27 p.m. OK Python 3 TESTS 46 452 307200 1900
49960961 MuhammedAbdalla A Feb. 15, 2019, 6:09 p.m. OK Python 3 TESTS 46 452 307200 1900
8781898 limed A Nov. 21, 2014, 5:58 p.m. OK Scala TESTS 46 280 102400 1900
13067603 reldan A Sept. 17, 2015, 1:21 p.m. OK Scala TESTS 46 280 204800 1900

remove filters

Back to search problems