Codeforces Round 144 (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
232 Codeforces Round 144 (Div. 1) FINISHED False 7200 387210563 Oct. 11, 2012, 3:30 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 2597 ) A Cycles PROGRAMMING binary search constructive algorithms graphs greedy 1800

B'John Doe started thinking about graphs. After some thought he decided that he wants to paint an undirected graph, containing exactly k cycles of length 3. A cycle of length 3 is an unordered group of three distinct graph vertices a, b and c, such that each pair of them is connected by a graph edge. John has been painting for long, but he has not been a success. Help him find such graph. Note that the number of vertices there shouldn 't exceed 100, or else John will have problems painting it. A single line contains an integer k (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89k xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89105) -- the number of cycles of length 3 in the required graph. In the first line print integer n (3 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89100) -- the number of vertices in the found graph. In each of next n lines print n characters "0" and "1": the i-th character of the j-th line should equal "0", if vertices i and j do not have an edge between them, otherwise it should equal "1". Note that as the required graph is undirected, the i-th character of the j-th line must equal the j-th character of the i-th line. The graph shouldn 't contain self-loops, so the i-th character of the i-th line must equal "0" for all i.'...

Tutorials

Editorial for Codeforces Round #144

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
54146842 rr_ A May 14, 2019, 8:06 p.m. OK D TESTS 46 62 4198400 1800
54146911 rr_ A May 14, 2019, 8:09 p.m. OK D TESTS 46 92 4198400 1800
2387362 Oryshych A Oct. 19, 2012, 12:47 p.m. OK Delphi TESTS 46 31 0 1800
2358154 Ramp A Oct. 14, 2012, 10:07 a.m. OK Delphi TESTS 46 31 0 1800
2358129 Misha100896 A Oct. 14, 2012, 9:56 a.m. OK Delphi TESTS 46 31 0 1800
2358106 Misha100896 A Oct. 14, 2012, 9:52 a.m. OK Delphi TESTS 46 31 0 1800
2353160 KaiZeR A Oct. 12, 2012, 7:11 p.m. OK Delphi TESTS 46 31 102400 1800
2350006 AleksanderBalobanov A Oct. 12, 2012, 6:33 a.m. OK Delphi TESTS 46 31 102400 1800
2346485 Anastasko A Oct. 11, 2012, 5:10 p.m. OK Delphi TESTS 46 31 102400 1800
2342715 kon_an A Oct. 11, 2012, 4:06 p.m. OK Delphi TESTS 46 31 102400 1800
2341289 Timur_Keks A Oct. 11, 2012, 3:48 p.m. OK Delphi TESTS 46 31 102400 1800
2344254 Frommi A Oct. 11, 2012, 4:29 p.m. OK Delphi TESTS 46 31 4096000 1800
2872759 Vad22 A Jan. 4, 2013, 9:49 a.m. OK FPC TESTS 46 15 0 1800
4203812 chipchip3412 A July 30, 2013, 11:03 a.m. OK FPC TESTS 46 30 0 1800
5112926 foreseeable A Nov. 15, 2013, 2:12 a.m. OK FPC TESTS 46 30 204800 1800
2474226 r.i A Oct. 31, 2012, 12:38 p.m. OK FPC TESTS 46 31 0 1800
2379221 zxh809444285 A Oct. 17, 2012, 12:29 p.m. OK FPC TESTS 46 31 0 1800
2360612 FHBPYP A Oct. 15, 2012, 10:30 a.m. OK FPC TESTS 46 31 0 1800
2352553 tennisru A Oct. 12, 2012, 4:10 p.m. OK FPC TESTS 46 31 0 1800
2349748 thaison1496 A Oct. 12, 2012, 4:12 a.m. OK FPC TESTS 46 31 0 1800
2349642 nhandi A Oct. 12, 2012, 2:57 a.m. OK FPC TESTS 46 31 0 1800
2346261 scorpion A Oct. 11, 2012, 5:06 p.m. OK FPC TESTS 46 31 0 1800
4097436 vjudge4 A July 18, 2013, 6:57 a.m. OK GNU C TESTS 46 15 0 1800
3412620 lxgsbqylbk A March 27, 2013, 3:50 p.m. OK GNU C TESTS 46 15 0 1800
2353720 vjtest A Oct. 13, 2012, 2:28 a.m. OK GNU C TESTS 46 31 0 1800
2347202 ali_fiujnomali A Oct. 11, 2012, 5:23 p.m. OK GNU C TESTS 46 31 0 1800
2341478 kawatea A Oct. 11, 2012, 3:50 p.m. OK GNU C TESTS 46 31 0 1800
2342884 stubbscroll A Oct. 11, 2012, 4:09 p.m. OK GNU C TESTS 46 46 204800 1800
4108381 akimonoiryou A July 19, 2013, 8:25 p.m. OK GNU C++ TESTS 46 15 0 1800
4108374 akimonoiryou A July 19, 2013, 8:21 p.m. OK GNU C++ TESTS 46 15 0 1800
4100745 Navid A July 18, 2013, 6:52 p.m. OK GNU C++ TESTS 46 15 0 1800
4099403 vjudge5 A July 18, 2013, 1:19 p.m. OK GNU C++ TESTS 46 15 0 1800
4096092 vjudge2 A July 18, 2013, 3:20 a.m. OK GNU C++ TESTS 46 15 0 1800
4096023 vjudge1 A July 18, 2013, 3:07 a.m. OK GNU C++ TESTS 46 15 0 1800
4095924 vjudge2 A July 18, 2013, 2:49 a.m. OK GNU C++ TESTS 46 15 0 1800
4095722 vjudge1 A July 18, 2013, 2:15 a.m. OK GNU C++ TESTS 46 15 0 1800
4095721 vjudge2 A July 18, 2013, 2:15 a.m. OK GNU C++ TESTS 46 15 0 1800
4095684 vjudge4 A July 18, 2013, 2:09 a.m. OK GNU C++ TESTS 46 15 0 1800
3756992 skrydg A May 22, 2013, 1:02 p.m. OK GNU C++0x TESTS 46 15 0 1800
3269092 EarlOfDitches A March 9, 2013, 9:26 a.m. OK GNU C++0x TESTS 46 15 0 1800
9781251 KerollosAsaad A Feb. 9, 2015, 3:16 p.m. OK GNU C++0x TESTS 46 30 0 1800
9228987 suchir A Dec. 23, 2014, 12:11 a.m. OK GNU C++0x TESTS 46 30 0 1800
7653591 maxkvant A Aug. 31, 2014, 11:29 a.m. OK GNU C++0x TESTS 46 30 0 1800
7537356 ztk A Aug. 20, 2014, 9:38 p.m. OK GNU C++0x TESTS 46 30 0 1800
6664310 fegla A May 20, 2014, 9:43 p.m. OK GNU C++0x TESTS 46 30 0 1800
6246029 k0st1a A April 2, 2014, 10:28 p.m. OK GNU C++0x TESTS 46 30 0 1800
5497163 marat.snowbear A Dec. 23, 2013, 1:50 p.m. OK GNU C++0x TESTS 46 30 0 1800
4215398 BOBAS A Aug. 2, 2013, 5:07 a.m. OK GNU C++0x TESTS 46 30 0 1800
58834115 rainboy A Aug. 14, 2019, 7:34 p.m. OK GNU C11 TESTS 46 62 0 1800
22097086 wwwwing A Nov. 7, 2016, 3:19 p.m. OK GNU C++11 TESTS 46 30 0 1800
22053008 Kusika A Nov. 5, 2016, 9:53 a.m. OK GNU C++11 TESTS 46 30 0 1800
21766071 pkk.tino A Oct. 25, 2016, 8 a.m. OK GNU C++11 TESTS 46 30 0 1800
20746487 aka.Sohieb A Sept. 19, 2016, 2:14 a.m. OK GNU C++11 TESTS 46 30 0 1800
20746453 aka.Sohieb A Sept. 19, 2016, 2:09 a.m. OK GNU C++11 TESTS 46 30 0 1800
16437119 yongwhan A March 1, 2016, 7:38 a.m. OK GNU C++11 TESTS 46 30 0 1800
16282518 Arpa A Feb. 22, 2016, 6:52 p.m. OK GNU C++11 TESTS 46 30 0 1800
16014390 49cryoke A Feb. 14, 2016, 7:44 a.m. OK GNU C++11 TESTS 46 30 0 1800
15834579 tun A Feb. 5, 2016, 11:13 p.m. OK GNU C++11 TESTS 46 30 0 1800
22307058 geniucos A Nov. 18, 2016, 1:19 p.m. OK GNU C++11 TESTS 46 30 0 1800
27753074 coder_in_makin A June 13, 2017, 10:07 a.m. OK GNU C++14 TESTS 46 30 0 1800
27459025 ei133333 A May 31, 2017, 4:27 a.m. OK GNU C++14 TESTS 46 30 0 1800
26884075 vjudge4 A May 5, 2017, 3:32 p.m. OK GNU C++14 TESTS 46 30 0 1800
22196750 weak_male A Nov. 13, 2016, 4:54 p.m. OK GNU C++14 TESTS 46 30 0 1800
21858529 First4196 A Oct. 28, 2016, 8:19 p.m. OK GNU C++14 TESTS 46 30 0 1800
20566349 MJS1997 A Sept. 13, 2016, 11:57 a.m. OK GNU C++14 TESTS 46 30 0 1800
31957855 yaksha A Nov. 1, 2017, 4:55 p.m. OK GNU C++14 TESTS 46 30 0 1800
31218703 Stronger2020 A Oct. 11, 2017, 2:16 p.m. OK GNU C++14 TESTS 46 30 102400 1800
30738737 deva2802 A Sept. 26, 2017, 2:43 a.m. OK GNU C++14 TESTS 46 30 102400 1800
55080499 bnmd A June 4, 2019, 10:31 a.m. OK GNU C++14 TESTS 46 30 102400 1800
56708949 ussef_abdallah A July 8, 2019, 12:04 p.m. OK GNU C++17 TESTS 46 30 102400 1800
36295845 zifeiy A March 15, 2018, 10:36 a.m. OK GNU C++17 TESTS 46 30 1945600 1800
55537121 Andrejj A June 13, 2019, 5:04 p.m. OK GNU C++17 TESTS 46 60 0 1800
51244506 pulsatio A March 13, 2019, 3:25 a.m. OK GNU C++17 TESTS 46 60 0 1800
46822184 dspataro A Dec. 9, 2018, 4 p.m. OK GNU C++17 TESTS 46 60 0 1800
55487158 chongryong A June 12, 2019, 8:24 a.m. OK GNU C++17 TESTS 46 60 102400 1800
50091711 Akikaze A Feb. 18, 2019, 10:45 a.m. OK GNU C++17 TESTS 46 60 204800 1800
38812637 alidadar7676 A May 31, 2018, 7:48 p.m. OK GNU C++17 TESTS 46 60 4403200 1800
69199949 LaSWeeG A Jan. 20, 2020, 4:11 p.m. OK GNU C++17 TESTS 46 62 0 1800
67680956 tnakao A Dec. 27, 2019, 6:21 a.m. OK GNU C++17 TESTS 46 62 0 1800
2362783 AntonDubovik A Oct. 16, 2012, 7:05 a.m. OK Haskell TESTS 46 46 0 1800
69794307 RetiredProgrammer A Jan. 29, 2020, 7:31 p.m. OK Java 11 TESTS 46 372 0 1800
66914939 zhanyi_xiaolu A Dec. 15, 2019, 5:56 a.m. OK Java 11 TESTS 46 374 0 1800
2345842 pyshnograev A Oct. 11, 2012, 4:58 p.m. OK Java 6 TESTS 46 93 102400 1800
2406037 lenny A Oct. 21, 2012, 8:54 p.m. OK Java 6 TESTS 46 93 102400 1800
2607311 gh_ost A Nov. 20, 2012, 7:04 p.m. OK Java 6 TESTS 46 93 204800 1800
2347542 VArtem A Oct. 11, 2012, 5:27 p.m. OK Java 6 TESTS 46 93 204800 1800
2345769 I-juice A Oct. 11, 2012, 4:56 p.m. OK Java 6 TESTS 46 93 204800 1800
2343129 hama-du A Oct. 11, 2012, 4:12 p.m. OK Java 6 TESTS 46 93 204800 1800
2342199 uwi A Oct. 11, 2012, 3:59 p.m. OK Java 6 TESTS 46 93 204800 1800
2342128 chavit A Oct. 11, 2012, 3:58 p.m. OK Java 6 TESTS 46 93 204800 1800
2360523 SpookyCookie A Oct. 15, 2012, 9:51 a.m. OK Java 6 TESTS 46 109 0 1800
2343568 Nox A Oct. 11, 2012, 4:19 p.m. OK Java 6 TESTS 46 109 102400 1800
2356047 jiangzhijie A Oct. 13, 2012, 4:35 p.m. OK Java 7 TESTS 46 93 0 1800
2348283 khanhptnk A Oct. 11, 2012, 6:36 p.m. OK Java 7 TESTS 46 93 0 1800
2342357 yarrr A Oct. 11, 2012, 4:01 p.m. OK Java 7 TESTS 46 93 0 1800
2340730 mrNobody A Oct. 11, 2012, 3:41 p.m. OK Java 7 TESTS 46 93 102400 1800
2360100 oimaster A Oct. 15, 2012, 7:07 a.m. OK Java 7 TESTS 46 109 0 1800
2343173 tanzaku A Oct. 11, 2012, 4:13 p.m. OK Java 7 TESTS 46 109 0 1800
2344001 OutSide A Oct. 11, 2012, 4:25 p.m. OK Java 7 TESTS 46 109 307200 1800
7211130 KNIGHT0X300 A July 23, 2014, 5:40 p.m. OK Java 7 TESTS 46 154 0 1800
6872660 alibaba A June 13, 2014, 11:09 a.m. OK Java 7 TESTS 46 154 0 1800
6570535 nickbuelich A May 8, 2014, 5:12 a.m. OK Java 7 TESTS 46 154 0 1800
38685716 IDzekh A May 28, 2018, 6:06 a.m. OK Java 8 TESTS 46 248 0 1800
27187447 pitfall A May 17, 2017, 10:17 p.m. OK Java 8 TESTS 46 248 0 1800
20613371 Omar_Morsi A Sept. 14, 2016, 12:05 p.m. OK Java 8 TESTS 46 248 0 1800
11730229 santa_calus A June 24, 2015, 2:43 a.m. OK Java 8 TESTS 46 248 0 1800
34215621 rahulkhairwar A Jan. 16, 2018, 7:46 a.m. OK Java 8 TESTS 46 248 21811200 1800
24789127 rahulkhairwar A Feb. 18, 2017, 8 p.m. OK Java 8 TESTS 46 278 20582400 1800
38684842 Slamur A May 28, 2018, 5:09 a.m. OK Java 8 TESTS 46 280 0 1800
40189326 KulikAlex A July 11, 2018, 5:20 a.m. OK Java 8 TESTS 46 280 0 1800
39698082 ViciousCoder A June 27, 2018, 10:11 a.m. OK Java 8 TESTS 46 280 0 1800
38608794 Tarun A May 25, 2018, 12:28 p.m. OK Java 8 TESTS 46 280 0 1800
2350532 mylifefordota A Oct. 12, 2012, 9:07 a.m. OK Mono C# TESTS 46 109 102400 1800
2343339 it4.kp A Oct. 11, 2012, 4:15 p.m. OK Mono C# TESTS 46 140 2457600 1800
23832289 og.kostya A Jan. 15, 2017, 6:53 a.m. OK MS C# TESTS 46 124 9318400 1800
3715911 RiKang A May 13, 2013, 9:38 a.m. OK MS C++ TESTS 46 15 0 1800
2961463 FreezingCool A Jan. 20, 2013, 2:43 a.m. OK MS C++ TESTS 46 15 0 1800
3364737 yejinru A March 21, 2013, 11:37 a.m. OK MS C++ TESTS 46 15 102400 1800
3853842 M.Mahdi A June 10, 2013, 12:14 p.m. OK MS C++ TESTS 46 15 8089600 1800
6513980 vjudge3 A May 1, 2014, 5:38 a.m. OK MS C++ TESTS 46 30 0 1800
9231472 vjudge2 A Dec. 23, 2014, 9:24 a.m. OK MS C++ TESTS 46 30 0 1800
6514682 vjudge3 A May 1, 2014, 7:57 a.m. OK MS C++ TESTS 46 30 0 1800
6514025 vjudge5 A May 1, 2014, 5:51 a.m. OK MS C++ TESTS 46 30 0 1800
6514648 vjudge4 A May 1, 2014, 7:53 a.m. OK MS C++ TESTS 46 30 102400 1800
6680840 k1nval A May 22, 2014, 11:22 a.m. OK MS C++ TESTS 46 30 102400 1800
33068384 yugle7 A Dec. 9, 2017, 8:13 p.m. OK PyPy 3 TESTS 46 218 23244800 1800
2352056 nealzane A Oct. 12, 2012, 2:14 p.m. OK Python 2 TESTS 46 62 0 1800
2351782 lyrics A Oct. 12, 2012, 1:18 p.m. OK Python 2 TESTS 46 62 0 1800
2345229 hota911 A Oct. 11, 2012, 4:47 p.m. OK Python 2 TESTS 46 62 0 1800
2354262 wangyue2002 A Oct. 13, 2012, 8 a.m. OK Python 2 TESTS 46 62 204800 1800
2379394 sleepiforest A Oct. 17, 2012, 12:52 p.m. OK Python 2 TESTS 46 109 0 1800
15914103 not_bot_but_POT A Feb. 9, 2016, 1:38 p.m. OK Python 2 TESTS 46 122 102400 1800
8358138 Temirulan A Oct. 23, 2014, 6:12 a.m. OK Python 2 TESTS 46 124 102400 1800
2360568 fish_ball A Oct. 15, 2012, 10:11 a.m. OK Python 2 TESTS 46 156 0 1800
46421375 mhorst A Nov. 30, 2018, 9:42 p.m. OK Python 2 TESTS 46 342 102400 1800
33070634 yugle7 A Dec. 10, 2017, 12:09 a.m. OK Python 3 TESTS 46 124 5529600 1800
33070677 yugle7 A Dec. 10, 2017, 12:16 a.m. OK Python 3 TESTS 46 154 5529600 1800
35849057 ______u______ A March 2, 2018, 5:07 p.m. OK Python 3 TESTS 46 154 5632000 1800
35848915 ______n______ A March 2, 2018, 5:06 p.m. OK Python 3 TESTS 46 154 5632000 1800
35848615 _____i_____ A March 2, 2018, 5:01 p.m. OK Python 3 TESTS 46 154 5632000 1800
35848566 _____k_____ A March 2, 2018, 5:01 p.m. OK Python 3 TESTS 46 154 5632000 1800
35841954 ______h______ A March 2, 2018, 2:44 p.m. OK Python 3 TESTS 46 154 5632000 1800
35841793 ______k______ A March 2, 2018, 2:42 p.m. OK Python 3 TESTS 46 154 5632000 1800
35841514 ______i______ A March 2, 2018, 2:37 p.m. OK Python 3 TESTS 46 154 5632000 1800
35838886 ______M______ A March 2, 2018, 1:42 p.m. OK Python 3 TESTS 46 154 5632000 1800
2347936 watashi A Oct. 11, 2012, 6:16 p.m. OK Ruby TESTS 46 125 0 1800

remove filters

Back to search problems