Educational Codeforces Round 72 (Rated for Div. 2)

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
1217 Educational Codeforces Round 72 (Rated for Div. 2) FINISHED False 7200 164129099 Sept. 5, 2019, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 11294 ) B Zmei Gorynich PROGRAMMING greedy math 1600

B"You are fighting with Zmei Gorynich -- a ferocious monster from Slavic myths, a huge dragon-like reptile with multiple heads! Initially Zmei Gorynich has x heads. You can deal n types of blows. If you deal a blow of the i -th type, you decrease the number of Gorynich's heads by min(d_i, curX) , there curX is the current number of heads. But if after this blow Zmei Gorynich has at least one head, he grows h_i new heads. If curX = 0 then Gorynich is defeated. You can deal each blow any number of times, in any order. For example, if curX = 10 , d = 7 , h = 10 then the number of heads changes to 13 (you cut 7 heads off, but then Zmei grows 10 new ones), but if curX = 10 , d = 11 , h = 100 then number of heads changes to 0 and Zmei Gorynich is considered defeated. Calculate the minimum number of blows to defeat Zmei Gorynich! You have to answer t independent queries. The first line contains one integer t ( 1 <= t <= 100 ) xe2 x80 x93 the number of queries. The first line of each query contains two integers n and x ( 1 <= n <= 100 , 1 <= x <= 10^9 ) -- the number of possible types of blows and the number of heads Zmei initially has, respectively. The following n lines of each query contain the descriptions of types of blows you can deal. The i -th line contains two integers d_i and h_i ( 1 <= d_i, h_i <= 10^9 ) -- the description of the i -th blow. For each query print the minimum number of blows you have to deal to defeat Zmei Gorynich. If Zmei Gorynuch cannot be defeated print -1 . In the first query you can deal the first blow (after that the number of heads changes to 10 - 6 + 3 = 7 ), and then deal the second blow. In the second query you just deal the first blow three times, and Zmei is defeated. In third query you can not defeat Zmei Gorynich. Maybe it's better to convince it "...

Tutorials

Educational Codeforces Round 72 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
61582123 vjudge1 B Oct. 1, 2019, 2:34 a.m. OK Clang++17 Diagnostics TESTS 365 61 0 1600
60170163 WhuNoel B Sept. 6, 2019, 12:35 p.m. OK Clang++17 Diagnostics TESTS 365 93 0 1600
60848592 Avitella B Sept. 19, 2019, 1:20 p.m. OK Clang++17 Diagnostics TESTS 365 124 8396800 1600
61095574 fluffyowl B Sept. 23, 2019, 2:38 a.m. OK D TESTS 365 46 0 1600
60178614 Minh2409 B Sept. 6, 2019, 3:22 p.m. OK FPC TESTS 365 46 0 1600
60498057 tranthanhtra B Sept. 13, 2019, 5:16 p.m. OK FPC TESTS 365 46 0 1600
60158211 SangTin B Sept. 6, 2019, 7:48 a.m. OK FPC TESTS 365 46 0 1600
60634244 eryihaha B Sept. 15, 2019, 12:44 p.m. OK GNU C11 TESTS 365 31 0 1600
60576035 vjudge4 B Sept. 14, 2019, 4:43 p.m. OK GNU C11 TESTS 365 31 0 1600
67784954 abcd227 B Dec. 28, 2019, 12:24 p.m. OK GNU C11 TESTS 365 31 0 1600
60473307 fwj B Sept. 13, 2019, 6:45 a.m. OK GNU C11 TESTS 365 31 0 1600
60327292 Winnerdevil B Sept. 10, 2019, 2:50 a.m. OK GNU C11 TESTS 365 31 0 1600
60325360 Keper6297 B Sept. 10, 2019, 12:42 a.m. OK GNU C11 TESTS 365 31 0 1600
67635815 Trinadh724 B Dec. 26, 2019, 6:53 a.m. OK GNU C11 TESTS 365 31 0 1600
65279932 no_words_to_sky B Nov. 18, 2019, 4:54 a.m. OK GNU C11 TESTS 365 31 0 1600
62456039 dedeepyayarlagadda2001 B Oct. 13, 2019, 6:28 a.m. OK GNU C11 TESTS 365 31 0 1600
61412700 sjx233 B Sept. 28, 2019, 9:15 a.m. OK GNU C11 TESTS 365 31 0 1600
68689435 ren_jian_cheng B Jan. 13, 2020, 5:22 a.m. OK GNU C++11 TESTS 365 31 0 1600
68638466 adzo261 B Jan. 12, 2020, 6:43 a.m. OK GNU C++11 TESTS 365 31 0 1600
68462731 vjudge1 B Jan. 9, 2020, 6:45 p.m. OK GNU C++11 TESTS 365 31 0 1600
67989490 fmln B Dec. 31, 2019, 3:12 a.m. OK GNU C++11 TESTS 365 31 0 1600
67498240 vjudge2 B Dec. 24, 2019, 1:46 a.m. OK GNU C++11 TESTS 365 31 0 1600
65749582 coder370 B Nov. 26, 2019, 1:32 p.m. OK GNU C++11 TESTS 365 31 0 1600
65126180 vjudge1 B Nov. 16, 2019, 2:27 a.m. OK GNU C++11 TESTS 365 31 0 1600
65122273 zhujunchao B Nov. 16, 2019, 2:26 a.m. OK GNU C++11 TESTS 365 31 0 1600
69546593 xtd B Jan. 26, 2020, 3:20 a.m. OK GNU C++11 TESTS 365 31 0 1600
69475102 SuhaibSawalha1 B Jan. 24, 2020, 3:52 p.m. OK GNU C++11 TESTS 365 31 0 1600
68829658 iamgoku_123 B Jan. 14, 2020, 9:09 p.m. OK GNU C++14 TESTS 365 31 0 1600
69049579 falconlover B Jan. 18, 2020, 12:13 p.m. OK GNU C++14 TESTS 365 31 0 1600
69209307 ashes0409 B Jan. 20, 2020, 7:14 p.m. OK GNU C++14 TESTS 365 31 0 1600
69434434 anshulgoel553 B Jan. 23, 2020, 6:26 p.m. OK GNU C++14 TESTS 365 31 0 1600
69498210 dnpshuser B Jan. 25, 2020, 5:24 a.m. OK GNU C++14 TESTS 365 31 0 1600
69546589 vjudge5 B Jan. 26, 2020, 3:20 a.m. OK GNU C++14 TESTS 365 31 0 1600
69643130 rivalq B Jan. 27, 2020, 10:18 p.m. OK GNU C++14 TESTS 365 31 0 1600
69687106 bhubam B Jan. 28, 2020, 5:22 p.m. OK GNU C++14 TESTS 365 31 0 1600
68654170 Robbie B Jan. 12, 2020, 11:43 a.m. OK GNU C++14 TESTS 365 31 0 1600
68412475 shogier B Jan. 8, 2020, 5:32 p.m. OK GNU C++14 TESTS 365 31 0 1600
67469081 kishan.06 B Dec. 23, 2019, 12:09 p.m. OK GNU C++17 TESTS 365 31 0 1600
69542813 0x0x0x0x0x0x0x0x0x0x B Jan. 25, 2020, 10:56 p.m. OK GNU C++17 TESTS 365 31 0 1600
69521225 JLU_GLHF B Jan. 25, 2020, 1:29 p.m. OK GNU C++17 TESTS 365 31 0 1600
68622683 maskMan B Jan. 11, 2020, 7:45 p.m. OK GNU C++17 TESTS 365 31 0 1600
68092676 Deemo B Jan. 2, 2020, 6:54 p.m. OK GNU C++17 TESTS 365 31 0 1600
68070999 ___X___ B Jan. 2, 2020, 10:16 a.m. OK GNU C++17 TESTS 365 31 0 1600
67982105 rajankur B Dec. 30, 2019, 7:52 p.m. OK GNU C++17 TESTS 365 31 0 1600
67974994 sashiming B Dec. 30, 2019, 4:32 p.m. OK GNU C++17 TESTS 365 31 0 1600
67664890 vjudge1 B Dec. 26, 2019, 5:26 p.m. OK GNU C++17 TESTS 365 31 0 1600
67413441 charity B Dec. 22, 2019, 9:05 a.m. OK GNU C++17 TESTS 365 31 0 1600
62178224 congbao B Oct. 9, 2019, 5:19 a.m. OK Go TESTS 365 46 0 1600
60459232 digiter B Sept. 12, 2019, 7:36 p.m. OK Go TESTS 365 46 0 1600
60454239 dSnix B Sept. 12, 2019, 5:12 p.m. OK Go TESTS 365 46 0 1600
61190172 sighduck B Sept. 24, 2019, 2:12 a.m. OK Go TESTS 365 62 0 1600
61118582 acafterwa B Sept. 23, 2019, 1:41 p.m. OK Go TESTS 365 592 0 1600
66037867 machhra B Nov. 30, 2019, 12:27 p.m. OK Java 11 TESTS 365 187 0 1600
67568652 lightseba B Dec. 24, 2019, 8:36 p.m. OK Java 11 TESTS 365 202 0 1600
65945700 30818 B Nov. 29, 2019, 8:31 a.m. OK Java 11 TESTS 365 233 0 1600
65945632 30818 B Nov. 29, 2019, 8:30 a.m. OK Java 11 TESTS 365 233 0 1600
64648370 ashanksingh1997 B Nov. 10, 2019, 4:01 p.m. OK Java 11 TESTS 365 233 0 1600
63504485 prateekk2001 B Oct. 26, 2019, 6:15 p.m. OK Java 8 TESTS 365 109 0 1600
67457035 Mann_27__ B Dec. 23, 2019, 7:24 a.m. OK Java 8 TESTS 365 124 0 1600
66677487 lazypanda B Dec. 12, 2019, 11:54 a.m. OK Java 8 TESTS 365 124 0 1600
64904250 phantom11 B Nov. 14, 2019, 8:35 p.m. OK Java 8 TESTS 365 124 0 1600
63933075 mayankarora21 B Oct. 31, 2019, 2:52 p.m. OK Java 8 TESTS 365 124 0 1600
63777713 Warbler B Oct. 30, 2019, 10:06 a.m. OK Java 8 TESTS 365 124 0 1600
62443766 tomars B Oct. 12, 2019, 9:03 p.m. OK Java 8 TESTS 365 124 0 1600
62150727 Oland B Oct. 8, 2019, 4:29 p.m. OK Java 8 TESTS 365 124 0 1600
61258734 kusomushi B Sept. 25, 2019, 11 a.m. OK Java 8 TESTS 365 124 0 1600
61089175 icpc_loser B Sept. 22, 2019, 8:04 p.m. OK Java 8 TESTS 365 124 0 1600
60150312 Spheniscine B Sept. 6, 2019, 3:32 a.m. OK Kotlin TESTS 365 155 0 1600
60531111 Kazim Quaternion B Sept. 14, 2019, 12:30 p.m. OK Kotlin TESTS 365 171 204800 1600
60205343 dkozak94 B Sept. 7, 2019, 7:53 a.m. OK Kotlin TESTS 365 171 204800 1600
60200052 plusplus6408 B Sept. 7, 2019, 5 a.m. OK Kotlin TESTS 365 171 204800 1600
60416332 SalmonTimo B Sept. 12, 2019, 2:30 a.m. OK Kotlin TESTS 365 187 204800 1600
60280628 Black_Fregat B Sept. 8, 2019, 8:36 p.m. OK Kotlin TESTS 365 187 204800 1600
60199733 plusplus6408 B Sept. 7, 2019, 4:42 a.m. OK Kotlin TESTS 365 187 204800 1600
60270906 wbars B Sept. 8, 2019, 3:27 p.m. OK Kotlin TESTS 365 202 512000 1600
60138794 Ahmadjon B Sept. 5, 2019, 7:15 p.m. OK Kotlin TESTS 365 233 204800 1600
60515483 LapsleyJuno SaurumanS B Sept. 14, 2019, 6:20 a.m. OK Mono C# TESTS 365 62 2355200 1600
61119175 Salatik231166 B Sept. 23, 2019, 1:52 p.m. OK Mono C# TESTS 365 62 2355200 1600
61136167 Peter111 B Sept. 23, 2019, 2:30 p.m. OK Mono C# TESTS 365 62 2457600 1600
60359218 treasuryonly B Sept. 10, 2019, 5:30 p.m. OK Mono C# TESTS 365 62 2457600 1600
60641020 Xtreemist B Sept. 15, 2019, 3:25 p.m. OK Mono C# TESTS 365 62 2457600 1600
60398633 TRR B Sept. 11, 2019, 3:52 p.m. OK Mono C# TESTS 365 62 2560000 1600
65318165 Tan42 B Nov. 18, 2019, 6:23 p.m. OK Mono C# TESTS 365 62 2662400 1600
61036955 Cybersys B Sept. 21, 2019, 8:24 p.m. OK Mono C# TESTS 365 62 2662400 1600
60204035 Efronzak B Sept. 7, 2019, 7:21 a.m. OK Mono C# TESTS 365 62 2662400 1600
60322187 ahmed-abdelsamee B Sept. 9, 2019, 9:12 p.m. OK Mono C# TESTS 365 62 2867200 1600
61752215 vjudge2 B Oct. 3, 2019, 3:58 a.m. OK MS C++ TESTS 365 31 0 1600
60592208 vjudge3 B Sept. 15, 2019, 2:59 a.m. OK MS C++ TESTS 365 31 0 1600
60592122 vjudge3 B Sept. 15, 2019, 2:56 a.m. OK MS C++ TESTS 365 31 0 1600
60590133 vjudge3 B Sept. 15, 2019, 1:26 a.m. OK MS C++ TESTS 365 31 0 1600
61827318 vjudge3 B Oct. 4, 2019, 5:20 a.m. OK MS C++ TESTS 365 31 0 1600
66788077 vjudge3 B Dec. 13, 2019, 2:20 p.m. OK MS C++ TESTS 365 31 0 1600
65279971 vjudge1 B Nov. 18, 2019, 4:56 a.m. OK MS C++ TESTS 365 31 0 1600
64150395 vjudge1 B Nov. 3, 2019, 11:13 a.m. OK MS C++ TESTS 365 31 0 1600
62613407 vjudge2 B Oct. 15, 2019, 10:37 a.m. OK MS C++ TESTS 365 31 0 1600
61399725 vjudge1 B Sept. 28, 2019, 4:34 a.m. OK MS C++ TESTS 365 31 0 1600
60174626 pmitkov B Sept. 6, 2019, 1:58 p.m. OK MS C++ 2017 TESTS 365 31 0 1600
64259003 vjudge1 B Nov. 4, 2019, 3:56 p.m. OK MS C++ 2017 TESTS 365 31 0 1600
65484157 vjudge1 B Nov. 21, 2019, 12:41 p.m. OK MS C++ 2017 TESTS 365 31 0 1600
60187507 j2v B Sept. 6, 2019, 7:17 p.m. OK MS C++ 2017 TESTS 365 31 0 1600
63294995 vjudge3 B Oct. 24, 2019, 12:45 p.m. OK MS C++ 2017 TESTS 365 31 0 1600
65260088 vjudge4 B Nov. 17, 2019, 2:45 p.m. OK MS C++ 2017 TESTS 365 46 0 1600
65259883 chenshouao B Nov. 17, 2019, 2:41 p.m. OK MS C++ 2017 TESTS 365 46 0 1600
65040771 920848348 B Nov. 15, 2019, 1:22 p.m. OK MS C++ 2017 TESTS 365 46 0 1600
63288994 vjudge1 B Oct. 24, 2019, 11:13 a.m. OK MS C++ 2017 TESTS 365 46 0 1600
63235674 vjudge5 B Oct. 23, 2019, 12:13 p.m. OK MS C++ 2017 TESTS 365 46 0 1600
60914407 mayxiaoyu B Sept. 20, 2019, 7:28 a.m. OK Node.js TESTS 365 171 4710400 1600
60918426 mayxiaoyu B Sept. 20, 2019, 9:25 a.m. OK Node.js TESTS 365 186 4812800 1600
60208558 Loremon B Sept. 7, 2019, 9:09 a.m. OK Node.js TESTS 365 186 5324800 1600
60886726 hnagamin B Sept. 19, 2019, 4:27 p.m. OK Ocaml TESTS 365 31 204800 1600
61004562 Julia-Kotova B Sept. 21, 2019, 10:45 a.m. OK PascalABC.NET TESTS 365 343 512000 1600
60139410 raj1307 B Sept. 5, 2019, 7:29 p.m. OK PyPy 2 TESTS 365 155 1945600 1600
66215374 xiaowuc1 B Dec. 3, 2019, 8:40 a.m. OK PyPy 2 TESTS 365 187 1433600 1600
60241996 yumtam B Sept. 7, 2019, 10:09 p.m. OK PyPy 2 TESTS 365 264 1638400 1600
60517289 thenewguy39 B Sept. 14, 2019, 7:12 a.m. OK PyPy 2 TESTS 365 296 7884800 1600
60237120 essi B Sept. 7, 2019, 7:01 p.m. OK PyPy 3 TESTS 365 155 2355200 1600
60418430 aalexx.s B Sept. 12, 2019, 4:10 a.m. OK PyPy 3 TESTS 365 170 2662400 1600
60405476 ma.maiorova B Sept. 11, 2019, 6:27 p.m. OK PyPy 3 TESTS 365 171 2867200 1600
60251128 dilesh.yadav.phe16 B Sept. 8, 2019, 6:50 a.m. OK PyPy 3 TESTS 365 171 2969600 1600
61076289 nikeshthapa255 B Sept. 22, 2019, 2:36 p.m. OK PyPy 3 TESTS 365 171 3072000 1600
60381613 ngsm B Sept. 11, 2019, 9:27 a.m. OK PyPy 3 TESTS 365 171 3481600 1600
60144600 normalboot B Sept. 5, 2019, 10:39 p.m. OK PyPy 3 TESTS 365 187 3072000 1600
60146522 Akash_123 B Sept. 6, 2019, 12:29 a.m. OK PyPy 3 TESTS 365 187 3276800 1600
60146564 Akash_123 B Sept. 6, 2019, 12:31 a.m. OK PyPy 3 TESTS 365 187 3379200 1600
60157901 littlewhywhat B Sept. 6, 2019, 7:39 a.m. OK PyPy 3 TESTS 365 187 3481600 1600
60248617 intspt B Sept. 8, 2019, 5:05 a.m. OK Python 2 TESTS 365 202 0 1600
60161001 phoenix28 B Sept. 6, 2019, 8:58 a.m. OK Python 2 TESTS 365 202 0 1600
60147183 MVP B Sept. 6, 2019, 1:09 a.m. OK Python 2 TESTS 365 218 0 1600
62599998 babpls B Oct. 15, 2019, 4:56 a.m. OK Python 3 TESTS 365 124 0 1600
61113380 S1lv3r B Sept. 23, 2019, 12:04 p.m. OK Python 3 TESTS 365 124 0 1600
60689641 Pymole B Sept. 16, 2019, 4:48 p.m. OK Python 3 TESTS 365 124 0 1600
60416558 ruacon130101 B Sept. 12, 2019, 2:43 a.m. OK Python 3 TESTS 365 124 0 1600
60415370 ruacon130101 B Sept. 12, 2019, 1:42 a.m. OK Python 3 TESTS 365 124 0 1600
60394801 Doshik B Sept. 11, 2019, 2:32 p.m. OK Python 3 TESTS 365 124 0 1600
60372393 NewPinC B Sept. 11, 2019, 3:27 a.m. OK Python 3 TESTS 365 124 0 1600
60361915 maslov.alex1580 B Sept. 10, 2019, 6:39 p.m. OK Python 3 TESTS 365 124 0 1600
60352369 sunyeul B Sept. 10, 2019, 2:47 p.m. OK Python 3 TESTS 365 124 0 1600
60337599 viler B Sept. 10, 2019, 9:18 a.m. OK Python 3 TESTS 365 124 0 1600
60143851 kalari499 B Sept. 5, 2019, 9:59 p.m. OK Ruby TESTS 365 93 204800 1600
60193123 A.K.Goharshady B Sept. 6, 2019, 11:02 p.m. OK Rust TESTS 365 46 0 1600
69719300 akiradeveloper B Jan. 29, 2020, 10:04 a.m. OK Rust TESTS 365 46 409600 1600
69709940 sansen B Jan. 29, 2020, 6:35 a.m. OK Rust TESTS 365 46 512000 1600
61574656 prituladima B Sept. 30, 2019, 8:08 p.m. OK Scala TESTS 365 436 0 1600

remove filters

Back to search problems