Mail.Ru Cup 2018 Round 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
1055 Mail.Ru Cup 2018 Round 2 FINISHED False 9000 189962699 Nov. 10, 2018, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 10771 ) A Metro PROGRAMMING graphs 1000

B"Alice has a birthday today, so she invited home her best friend Bob. Now Bob needs to find a way to commute to the Alice's home. In the city in which Alice and Bob live, the first metro line is being built. This metro line contains n stations numbered from 1 to n . Bob lives near the station with number 1 , while Alice lives near the station with number s . The metro line has two tracks. Trains on the first track go from the station 1 to the station n and trains on the second track go in reverse direction. Just after the train arrives to the end of its track, it goes to the depot immediately, so it is impossible to travel on it after that. Some stations are not yet open at all and some are only partially open -- for each station and for each track it is known whether the station is closed for that track or not. If a station is closed for some track, all trains going in this track's direction pass the station without stopping on it. When the Bob got the information on opened and closed stations, he found that traveling by metro may be unexpectedly complicated. Help Bob determine whether he can travel to the Alice's home by metro or he should search for some other transport. The first line contains two integers n and s ( 2 <= s <= n <= 1000 ) -- the number of stations in the metro and the number of the station where Alice's home is located. Bob lives at station 1 . Next lines describe information about closed and open stations. The second line contains n integers a_1, a_2, ldots, a_n ( a_i = 0 or a_i = 1 ). If a_i = 1 , then the i -th station is open on the first track (that is, in the direction of increasing station numbers). Otherwise the station is closed on the first track. The third line contains n integers b_1, b_2, ldots, b_n ( b_i = 0 or b_i = 1 ). If b_i = 1 , then the i -th station is open on the second track (that is"...

Tutorials

Mail.Ru Cup 2018 Round 2 — analysis

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
45699393 hector_ A Nov. 14, 2018, 7 a.m. OK Clang++17 Diagnostics TESTS 56 46 307200 1000
46863109 yafngzh A Dec. 10, 2018, 4:58 p.m. OK Clang++17 Diagnostics TESTS 56 46 307200 1000
49024906 salsabil.sehli A Jan. 26, 2019, 6:35 p.m. OK Clang++17 Diagnostics TESTS 56 109 2150400 1000
45516614 Gassa A Nov. 10, 2018, 2:47 p.m. OK D TESTS 56 31 4198400 1000
45514855 ruban A Nov. 10, 2018, 2:42 p.m. OK Delphi TESTS 56 31 73216000 1000
45566348 ruban A Nov. 11, 2018, 2:45 p.m. OK Delphi TESTS 56 31 109670400 1000
50041738 vjudge1 A Feb. 17, 2019, 2:35 a.m. OK FPC TESTS 56 31 0 1000
57497806 hoangwvn246813579 A July 22, 2019, 9:06 a.m. OK FPC TESTS 56 31 0 1000
57498074 hzhzhz5 A July 22, 2019, 9:11 a.m. OK FPC TESTS 56 31 0 1000
45517027 LeoPro A Nov. 10, 2018, 2:49 p.m. OK FPC TESTS 56 31 0 1000
51410547 thantrongtri3 A March 17, 2019, 11:53 a.m. OK FPC TESTS 56 31 0 1000
46355527 artyomshpl12345 A Nov. 29, 2018, 8:03 a.m. OK FPC TESTS 56 31 0 1000
45566525 CallBoy A Nov. 11, 2018, 2:53 p.m. OK FPC TESTS 56 31 0 1000
45554679 PandaIsTheBest A Nov. 11, 2018, 7:49 a.m. OK FPC TESTS 56 31 0 1000
45519132 PAG A Nov. 10, 2018, 2:57 p.m. OK FPC TESTS 56 31 0 1000
51262375 hudshiy_drug A March 13, 2019, 1:53 p.m. OK FPC TESTS 56 31 307200 1000
45518910 Satnam_412 A Nov. 10, 2018, 2:56 p.m. OK GNU C11 TESTS 56 30 0 1000
56883446 You_Know_Who A July 12, 2019, 11:30 a.m. OK GNU C11 TESTS 56 31 0 1000
60400432 ratul_supertramp A Sept. 11, 2019, 4:29 p.m. OK GNU C11 TESTS 56 31 0 1000
62568608 DevJewel A Oct. 14, 2019, 1:51 p.m. OK GNU C11 TESTS 56 31 0 1000
65922082 lazybear A Nov. 28, 2019, 4:44 p.m. OK GNU C11 TESTS 56 31 0 1000
65922152 Roman70 A Nov. 28, 2019, 4:45 p.m. OK GNU C11 TESTS 56 31 0 1000
65922285 Stanislav_Pushkashu A Nov. 28, 2019, 4:48 p.m. OK GNU C11 TESTS 56 31 0 1000
66735251 MoldovaIT A Dec. 12, 2019, 6:33 p.m. OK GNU C11 TESTS 56 31 0 1000
66813654 RajMaheshwari A Dec. 14, 2019, 4:33 a.m. OK GNU C11 TESTS 56 31 0 1000
67487663 Ankan_Saha A Dec. 23, 2019, 6:06 p.m. OK GNU C11 TESTS 56 31 0 1000
62050041 vjudge5 A Oct. 7, 2019, 9:10 a.m. OK GNU C++11 TESTS 56 30 0 1000
45515324 lezdzh A Nov. 10, 2018, 2:43 p.m. OK GNU C++11 TESTS 56 30 0 1000
45553124 201601060805 A Nov. 11, 2018, 6:58 a.m. OK GNU C++11 TESTS 56 30 0 1000
49024778 hajer_souissi A Jan. 26, 2019, 6:31 p.m. OK GNU C++11 TESTS 56 30 0 1000
57868406 lopare A July 27, 2019, 11:13 p.m. OK GNU C++11 TESTS 56 30 0 1000
45514474 sl4154 A Nov. 10, 2018, 2:41 p.m. OK GNU C++11 TESTS 56 30 0 1000
69385428 pcruiher08 A Jan. 22, 2020, 9:58 p.m. OK GNU C++11 TESTS 56 31 0 1000
69400886 levi.ackerman1732 A Jan. 23, 2020, 8:44 a.m. OK GNU C++11 TESTS 56 31 0 1000
69924257 duality A Jan. 31, 2020, 7:37 p.m. OK GNU C++11 TESTS 56 31 0 1000
69385239 Aast A Jan. 22, 2020, 9:48 p.m. OK GNU C++11 TESTS 56 31 0 1000
45783489 eidan A Nov. 15, 2018, 9:51 p.m. OK GNU C++14 TESTS 56 15 0 1000
55844326 dhruv_garg A June 20, 2019, 8:05 p.m. OK GNU C++14 TESTS 56 15 0 1000
54060686 nidhi_099 A May 13, 2019, 11:05 a.m. OK GNU C++14 TESTS 56 15 0 1000
53731886 maheshwarishubh98 A May 4, 2019, 7:38 a.m. OK GNU C++14 TESTS 56 15 0 1000
47714575 Kishan_16 A Dec. 30, 2018, 6:42 a.m. OK GNU C++14 TESTS 56 15 0 1000
46620658 avnish_002 A Dec. 4, 2018, 5:59 p.m. OK GNU C++14 TESTS 56 15 0 1000
46247380 x_zadfar A Nov. 26, 2018, 12:13 p.m. OK GNU C++14 TESTS 56 15 0 1000
46192452 sparsh95 A Nov. 25, 2018, 6:16 a.m. OK GNU C++14 TESTS 56 15 0 1000
45570105 shehabkhalid A Nov. 11, 2018, 5:16 p.m. OK GNU C++14 TESTS 56 15 0 1000
45553061 anshubj A Nov. 11, 2018, 6:55 a.m. OK GNU C++14 TESTS 56 15 0 1000
45580301 ecnerwala A Nov. 12, 2018, 3:26 a.m. OK GNU C++17 TESTS 56 15 0 1000
55668890 nor A June 17, 2019, 6:14 a.m. OK GNU C++17 TESTS 56 15 0 1000
59665300 Juve45 A Aug. 29, 2019, 1:59 p.m. OK GNU C++17 TESTS 56 15 0 1000
45554451 ghoast A Nov. 11, 2018, 7:42 a.m. OK GNU C++17 TESTS 56 15 307200 1000
45579767 Asif_Mohammad A Nov. 12, 2018, 2:47 a.m. OK GNU C++17 TESTS 56 15 307200 1000
45584563 chierqj A Nov. 12, 2018, 7:32 a.m. OK GNU C++17 TESTS 56 15 307200 1000
47892841 niskh A Jan. 4, 2019, 8:04 a.m. OK GNU C++17 TESTS 56 15 307200 1000
45514046 D.Pavlenko A Nov. 10, 2018, 2:39 p.m. OK GNU C++17 TESTS 56 15 307200 1000
45516719 tyler A Nov. 10, 2018, 2:48 p.m. OK GNU C++17 TESTS 56 15 307200 1000
45517505 xuzimao0502 A Nov. 10, 2018, 2:51 p.m. OK GNU C++17 TESTS 56 15 307200 1000
48697186 oserde A Jan. 21, 2019, 11:19 p.m. OK Go TESTS 56 31 0 1000
45519719 life_is_not_bed_of_roses A Nov. 10, 2018, 3 p.m. OK Go TESTS 56 31 0 1000
45528989 yuma25689 A Nov. 10, 2018, 3:57 p.m. OK Go TESTS 56 46 0 1000
45520546 Flaker A Nov. 10, 2018, 3:04 p.m. OK Go TESTS 56 46 0 1000
45660625 guptautkarsh028 A Nov. 13, 2018, 6:21 a.m. OK Java 8 TESTS 56 108 0 1000
61278966 maheshwari29 A Sept. 25, 2019, 4:23 p.m. OK Java 8 TESTS 56 109 0 1000
58996684 lansergecs A Aug. 18, 2019, 11:43 a.m. OK Java 8 TESTS 56 109 0 1000
55843832 YousseF_Diaa A June 20, 2019, 7:45 p.m. OK Java 8 TESTS 56 109 0 1000
54988337 Nothing199 A June 2, 2019, 5:02 p.m. OK Java 8 TESTS 56 109 0 1000
52746594 Jarik A April 14, 2019, 11:59 a.m. OK Java 8 TESTS 56 109 0 1000
50621960 Harbin A March 1, 2019, 2:36 a.m. OK Java 8 TESTS 56 109 0 1000
50104373 CharlesDai A Feb. 18, 2019, 3:45 p.m. OK Java 8 TESTS 56 109 0 1000
49450649 kissscreen A Feb. 4, 2019, 6:57 a.m. OK Java 8 TESTS 56 109 0 1000
49450510 bulat_khaf31 A Feb. 4, 2019, 6:52 a.m. OK Java 8 TESTS 56 109 0 1000
46454334 luigiop A Dec. 1, 2018, 5:31 p.m. OK JavaScript TESTS 56 31 0 1000
45525132 v.kristina A Nov. 10, 2018, 3:30 p.m. OK JavaScript TESTS 56 46 0 1000
45542754 kamil_hism A Nov. 10, 2018, 8:37 p.m. OK JavaScript TESTS 56 46 1126400 1000
45514216 shaviava A Nov. 10, 2018, 2:40 p.m. OK Kotlin TESTS 56 124 0 1000
54848967 slemus A May 30, 2019, 3:31 p.m. OK Kotlin TESTS 56 139 0 1000
45520994 tumoyakov A Nov. 10, 2018, 3:06 p.m. OK Kotlin TESTS 56 140 0 1000
45516621 mrfoxygmfr A Nov. 10, 2018, 2:47 p.m. OK Kotlin TESTS 56 155 0 1000
45515965 alexey.enkov A Nov. 10, 2018, 2:45 p.m. OK Kotlin TESTS 56 155 102400 1000
45531418 jedikni A Nov. 10, 2018, 4:16 p.m. OK Kotlin TESTS 56 155 102400 1000
45515635 raynald A Nov. 10, 2018, 2:44 p.m. OK Kotlin TESTS 56 155 102400 1000
55976782 og.kostya A June 23, 2019, 5:59 p.m. OK Mono C# TESTS 56 46 0 1000
45572451 W0lfEnstein A Nov. 11, 2018, 6:57 p.m. OK Mono C# TESTS 56 46 0 1000
45515192 eki A Nov. 10, 2018, 2:43 p.m. OK Mono C# TESTS 56 46 102400 1000
45539625 tattosha_aptan A Nov. 10, 2018, 6:40 p.m. OK Mono C# TESTS 56 61 0 1000
45523380 Janonsky A Nov. 10, 2018, 3:19 p.m. OK Mono C# TESTS 56 61 0 1000
46239318 DanilaMaestro A Nov. 26, 2018, 6:36 a.m. OK Mono C# TESTS 56 61 0 1000
45542020 kuuso A Nov. 10, 2018, 8:04 p.m. OK Mono C# TESTS 56 61 1740800 1000
54085662 aleks180700 A May 14, 2019, 7:12 a.m. OK Mono C# TESTS 56 61 3686400 1000
47415460 tamunsio A Dec. 23, 2018, 2:21 p.m. OK Mono C# TESTS 56 62 0 1000
45552233 Gray_Rhino A Nov. 11, 2018, 6:22 a.m. OK Mono C# TESTS 56 62 0 1000
61321479 vjudge5 A Sept. 26, 2019, 12:42 p.m. OK MS C++ TESTS 56 31 0 1000
64127238 vjudge1 A Nov. 3, 2019, 5:25 a.m. OK MS C++ TESTS 56 31 0 1000
64130526 vjudge2 A Nov. 3, 2019, 6:41 a.m. OK MS C++ TESTS 56 31 0 1000
66172858 vjudge4 A Dec. 2, 2019, 11:13 a.m. OK MS C++ TESTS 56 31 0 1000
66485767 vjudge4 A Dec. 8, 2019, 6:17 a.m. OK MS C++ TESTS 56 31 0 1000
66490159 vjudge1 A Dec. 8, 2019, 8:15 a.m. OK MS C++ TESTS 56 31 0 1000
56986576 shio A July 13, 2019, 4:04 p.m. OK MS C++ TESTS 56 31 0 1000
59419212 Neri A Aug. 24, 2019, 7:55 p.m. OK MS C++ TESTS 56 31 0 1000
56983013 lxy13798569558 A July 13, 2019, 2:41 p.m. OK MS C++ TESTS 56 31 0 1000
61158610 vjudge1 A Sept. 23, 2019, 3:35 p.m. OK MS C++ TESTS 56 31 0 1000
51668036 XDIMANX007 A March 22, 2019, 6:58 a.m. OK MS C++ 2017 TESTS 56 31 0 1000
66489514 vjudge2 A Dec. 8, 2019, 7:58 a.m. OK MS C++ 2017 TESTS 56 31 0 1000
65601603 BorONE A Nov. 23, 2019, 6:21 p.m. OK MS C++ 2017 TESTS 56 31 0 1000
63514449 vsulovyev A Oct. 26, 2019, 10:43 p.m. OK MS C++ 2017 TESTS 56 31 0 1000
62646792 Moen1578 A Oct. 15, 2019, 7:50 p.m. OK MS C++ 2017 TESTS 56 31 0 1000
62646658 Moen1578 A Oct. 15, 2019, 7:47 p.m. OK MS C++ 2017 TESTS 56 31 0 1000
61552061 HPV A Sept. 30, 2019, 12:48 p.m. OK MS C++ 2017 TESTS 56 31 0 1000
55233608 Mad112233 A June 7, 2019, 7:08 a.m. OK MS C++ 2017 TESTS 56 31 0 1000
52264430 lippert A April 3, 2019, 10:44 a.m. OK MS C++ 2017 TESTS 56 31 0 1000
50578213 ersul A Feb. 27, 2019, 7:19 p.m. OK MS C++ 2017 TESTS 56 31 0 1000
45542857 sk0 A Nov. 10, 2018, 8:41 p.m. OK Ocaml TESTS 56 31 307200 1000
45517222 Arcadii A Nov. 10, 2018, 2:50 p.m. OK PascalABC.NET TESTS 56 46 0 1000
45515940 OpKos A Nov. 10, 2018, 2:45 p.m. OK PascalABC.NET TESTS 56 46 0 1000
45524785 m_irina A Nov. 10, 2018, 3:28 p.m. OK PascalABC.NET TESTS 56 61 409600 1000
45519104 Alex_D A Nov. 10, 2018, 2:57 p.m. OK PascalABC.NET TESTS 56 61 409600 1000
45627822 KGYYT A Nov. 12, 2018, 4:26 p.m. OK PascalABC.NET TESTS 56 62 307200 1000
45523404 Phloyd A Nov. 10, 2018, 3:19 p.m. OK PascalABC.NET TESTS 56 62 409600 1000
51260391 vippee A March 13, 2019, 1:04 p.m. OK PascalABC.NET TESTS 56 187 0 1000
51259535 vippee A March 13, 2019, 12:46 p.m. OK PascalABC.NET TESTS 56 202 0 1000
48864786 kirilllee A Jan. 24, 2019, 2:13 a.m. OK PascalABC.NET TESTS 56 327 307200 1000
45543776 rsFalse A Nov. 10, 2018, 9:30 p.m. OK Perl TESTS 56 31 0 1000
45524206 adromaryn A Nov. 10, 2018, 3:24 p.m. OK Perl TESTS 56 233 307200 1000
45535000 katalama A Nov. 10, 2018, 4:46 p.m. OK PHP TESTS 56 46 409600 1000
45555177 mayakin A Nov. 11, 2018, 8:07 a.m. OK PHP TESTS 56 46 409600 1000
45513916 alexwice A Nov. 10, 2018, 2:38 p.m. OK PyPy 2 TESTS 56 124 102400 1000
45518201 figdan A Nov. 10, 2018, 2:53 p.m. OK PyPy 2 TESTS 56 124 204800 1000
45516669 wangkan2001 A Nov. 10, 2018, 2:47 p.m. OK PyPy 2 TESTS 56 124 204800 1000
45515212 abhigyank A Nov. 10, 2018, 2:43 p.m. OK PyPy 2 TESTS 56 124 204800 1000
45515006 NicotineAddict A Nov. 10, 2018, 2:42 p.m. OK PyPy 2 TESTS 56 124 204800 1000
54550450 chaudhary_19 A May 24, 2019, 8:47 a.m. OK PyPy 2 TESTS 56 124 307200 1000
45525084 m.zharkov.118855 A Nov. 10, 2018, 3:30 p.m. OK PyPy 2 TESTS 56 139 102400 1000
45520569 soumyasarkar1998 A Nov. 10, 2018, 3:04 p.m. OK PyPy 2 TESTS 56 139 102400 1000
45517428 Anunay1605 A Nov. 10, 2018, 2:50 p.m. OK PyPy 2 TESTS 56 139 102400 1000
45515346 frederika A Nov. 10, 2018, 2:43 p.m. OK PyPy 2 TESTS 56 139 307200 1000
45571573 Leendertz A Nov. 11, 2018, 6:16 p.m. OK PyPy 3 TESTS 56 124 0 1000
45567357 malo.detz A Nov. 11, 2018, 3:23 p.m. OK PyPy 3 TESTS 56 139 0 1000
45552063 hrustim25 A Nov. 11, 2018, 6:13 a.m. OK PyPy 3 TESTS 56 139 0 1000
45528466 nguyenhuuhuan A Nov. 10, 2018, 3:53 p.m. OK PyPy 3 TESTS 56 139 0 1000
59861551 teexone A Sept. 1, 2019, 3:31 p.m. OK PyPy 3 TESTS 56 140 0 1000
58852041 nikitaqqqq A Aug. 15, 2019, 7:52 a.m. OK PyPy 3 TESTS 56 140 0 1000
55971602 Baron3228 A June 23, 2019, 3:09 p.m. OK PyPy 3 TESTS 56 140 0 1000
51261841 KrisAlan A March 13, 2019, 1:40 p.m. OK PyPy 3 TESTS 56 140 0 1000
50388954 Noafraid A Feb. 23, 2019, 1:19 p.m. OK PyPy 3 TESTS 56 140 0 1000
48443331 AbduSharif A Jan. 16, 2019, 5:56 a.m. OK PyPy 3 TESTS 56 140 0 1000
47549654 franckmy A Dec. 27, 2018, 12:19 p.m. OK Python 2 TESTS 56 171 0 1000
45751250 adair A Nov. 15, 2018, 1:21 a.m. OK Python 2 TESTS 56 171 0 1000
45564195 HigorSnt A Nov. 11, 2018, 1:25 p.m. OK Python 2 TESTS 56 171 0 1000
45552800 daminglu A Nov. 11, 2018, 6:45 a.m. OK Python 2 TESTS 56 171 0 1000
45550344 xiaoshiwang22 A Nov. 11, 2018, 4:36 a.m. OK Python 2 TESTS 56 171 0 1000
45539225 kaif_7 A Nov. 10, 2018, 6:30 p.m. OK Python 2 TESTS 56 171 0 1000
45537352 Ivan_Gordiy A Nov. 10, 2018, 5:03 p.m. OK Python 2 TESTS 56 171 0 1000
45536761 xiaohuihui A Nov. 10, 2018, 4:59 p.m. OK Python 2 TESTS 56 171 0 1000
45524179 Mulx10 A Nov. 10, 2018, 3:24 p.m. OK Python 2 TESTS 56 171 0 1000
45521319 abhishekm71 A Nov. 10, 2018, 3:08 p.m. OK Python 2 TESTS 56 171 0 1000
53341703 ayoobch A April 26, 2019, 3:20 p.m. OK Python 3 TESTS 56 108 0 1000
49015405 baccari A Jan. 26, 2019, 5 p.m. OK Python 3 TESTS 56 108 0 1000
63679854 jvrbferrer A Oct. 28, 2019, 7:34 p.m. OK Python 3 TESTS 56 109 0 1000
63451482 the_oathbreaker A Oct. 26, 2019, 11:23 a.m. OK Python 3 TESTS 56 109 0 1000
62556798 Pymole A Oct. 14, 2019, 10:49 a.m. OK Python 3 TESTS 56 109 0 1000
60779883 Liquid_1331 A Sept. 18, 2019, 3:53 p.m. OK Python 3 TESTS 56 109 0 1000
58401017 shall_not_pass A Aug. 6, 2019, 5:48 p.m. OK Python 3 TESTS 56 109 0 1000
56036948 cs1g A June 25, 2019, 12:31 p.m. OK Python 3 TESTS 56 109 0 1000
52025073 chauhain A March 30, 2019, 2:28 p.m. OK Python 3 TESTS 56 109 0 1000
50047283 lIn_nIl A Feb. 17, 2019, 6:34 a.m. OK Python 3 TESTS 56 109 0 1000
45544185 Karnaj A Nov. 10, 2018, 9:57 p.m. OK Ruby TESTS 56 62 102400 1000
45520255 mash97 A Nov. 10, 2018, 3:02 p.m. OK Ruby TESTS 56 62 102400 1000
45516773 AnandVeeramani A Nov. 10, 2018, 2:48 p.m. OK Ruby TESTS 56 78 102400 1000
54885049 purvasinghvi31 A May 31, 2019, 4:44 p.m. OK Ruby TESTS 56 93 102400 1000
45518863 AAcapOK A Nov. 10, 2018, 2:56 p.m. OK Rust TESTS 56 31 0 1000
45534282 tian_feng_bo A Nov. 10, 2018, 4:40 p.m. OK Scala TESTS 56 452 0 1000
45520778 truongbom A Nov. 10, 2018, 3:05 p.m. OK Scala TESTS 56 467 0 1000
45514260 yakamoto A Nov. 10, 2018, 2:40 p.m. OK Scala TESTS 56 483 0 1000
45514566 limed A Nov. 10, 2018, 2:41 p.m. OK Scala TESTS 56 561 0 1000

remove filters

Back to search problems