Codeforces Round 580 (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
1205 Codeforces Round 580 (Div. 1) FINISHED False 7800 165687299 Aug. 18, 2019, 1:45 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 6721 ) B Shortest Cycle PROGRAMMING bitmasks brute force graphs shortest paths 1900

B"You are given n integer numbers a_1, a_2, ... , a_n . Consider graph on n nodes, in which nodes i , j ( i neq j ) are connected if and only if, a_i AND a_j neq 0 , where AND denotes the bitwise AND operation. Find the length of the shortest cycle in this graph or determine that it doesn't have cycles at all. The first line contains one integer n (1 <= n <= 10^5) -- number of numbers. The second line contains n integer numbers a_1, a_2, ... , a_n ( 0 <= a_i <= 10^{18} ). If the graph doesn't have any cycles, output -1 . Else output the length of the shortest cycle. In the first example, the shortest cycle is (9, 3, 6, 28) . In the second example, the shortest cycle is (5, 12, 9) . The graph has no cycles in the third example. "...

Tutorials

69158

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
59091762 NoSoul B Aug. 19, 2019, 12:58 p.m. OK GNU C11 TESTS 88 61 819200 1900
59026599 _rqy B Aug. 18, 2019, 2:36 p.m. OK GNU C++11 TESTS 83 31 0 1900
59069401 Starlit B Aug. 19, 2019, 3:47 a.m. OK GNU C++11 TESTS 86 31 0 1900
59273234 hcmdgh B Aug. 22, 2019, 1:30 p.m. OK GNU C++11 TESTS 88 31 0 1900
59702175 YangDavid B Aug. 30, 2019, 11:08 a.m. OK GNU C++11 TESTS 88 31 102400 1900
59214638 -Artistic_Fantasy B Aug. 21, 2019, 9:44 a.m. OK GNU C++11 TESTS 88 31 102400 1900
64875787 Depth_First_Search B Nov. 14, 2019, 9:47 a.m. OK GNU C++11 TESTS 88 31 102400 1900
59849469 hovny B Sept. 1, 2019, 10:53 a.m. OK GNU C++11 TESTS 88 31 204800 1900
59709936 luogu_bot1 B Aug. 30, 2019, 2:15 p.m. OK GNU C++11 TESTS 88 31 204800 1900
59216738 ___sss B Aug. 21, 2019, 10:36 a.m. OK GNU C++11 TESTS 88 31 204800 1900
63697664 kcn999 B Oct. 29, 2019, 6:07 a.m. OK GNU C++11 TESTS 88 31 204800 1900
60694845 ionut_dobricean B Sept. 16, 2019, 7:05 p.m. OK GNU C++14 TESTS 88 31 307200 1900
59258707 wcs152 B Aug. 22, 2019, 7:42 a.m. OK GNU C++14 TESTS 88 31 307200 1900
59118758 Sparta_KP B Aug. 20, 2019, 3:29 a.m. OK GNU C++14 TESTS 88 31 307200 1900
61825118 strange B Oct. 4, 2019, 4:22 a.m. OK GNU C++14 TESTS 88 31 307200 1900
60216245 mobu233 B Sept. 7, 2019, 11:57 a.m. OK GNU C++14 TESTS 88 31 819200 1900
59067714 vjudge3 B Aug. 19, 2019, 2:48 a.m. OK GNU C++14 TESTS 86 31 921600 1900
59103620 ILSM B Aug. 19, 2019, 5:05 p.m. OK GNU C++14 TESTS 88 31 921600 1900
59058577 igorpastukh B Aug. 18, 2019, 8:07 p.m. OK GNU C++14 TESTS 85 31 2150400 1900
65952620 Heart_Blue B Nov. 29, 2019, 11:30 a.m. OK GNU C++14 TESTS 88 31 2764800 1900
61761927 LanrTabe B Oct. 3, 2019, 7:23 a.m. OK GNU C++14 TESTS 88 46 102400 1900
61964505 itachikesh B Oct. 6, 2019, 8:27 a.m. OK GNU C++17 TESTS 88 31 0 1900
59694642 DevilInChina B Aug. 30, 2019, 7:58 a.m. OK GNU C++17 TESTS 88 31 102400 1900
59119562 wangxi B Aug. 20, 2019, 4:07 a.m. OK GNU C++17 TESTS 88 31 102400 1900
59625152 hyper_sinnniy B Aug. 28, 2019, 3:38 p.m. OK GNU C++17 TESTS 88 31 204800 1900
59028300 hugopm B Aug. 18, 2019, 2:41 p.m. OK GNU C++17 TESTS 83 31 204800 1900
59090607 YellowJ B Aug. 19, 2019, 12:38 p.m. OK GNU C++17 TESTS 88 31 307200 1900
59035441 tfg B Aug. 18, 2019, 3:09 p.m. OK GNU C++17 TESTS 83 31 921600 1900
59203493 jiangly B Aug. 21, 2019, 6:01 a.m. OK GNU C++17 TESTS 88 31 8601600 1900
62181558 Qingyu B Oct. 9, 2019, 6:39 a.m. OK GNU C++17 TESTS 88 31 9728000 1900
62181514 Qingyu B Oct. 9, 2019, 6:38 a.m. OK GNU C++17 TESTS 88 31 9728000 1900
61731346 sighduck B Oct. 2, 2019, 4:51 p.m. OK Go TESTS 88 140 4505600 1900
62088439 synapse B Oct. 8, 2019, 4:09 a.m. OK Go TESTS 88 217 29081600 1900
63945297 KulikAlex B Oct. 31, 2019, 6:43 p.m. OK Java 11 TESTS 88 311 819200 1900
59254864 uwi B Aug. 22, 2019, 6:08 a.m. OK Java 8 TESTS 88 124 0 1900
59528277 yaoct B Aug. 26, 2019, 2:07 p.m. OK Java 8 TESTS 88 124 2969600 1900
59254674 uwi B Aug. 22, 2019, 6:03 a.m. OK Java 8 TESTS 88 139 0 1900
59113838 GiantTornado B Aug. 19, 2019, 11:43 p.m. OK Java 8 TESTS 88 140 2867200 1900
59052673 fetetriste B Aug. 18, 2019, 5:48 p.m. OK Java 8 TESTS 85 140 3072000 1900
59636671 sarthakmanna B Aug. 28, 2019, 9:10 p.m. OK Java 8 TESTS 88 155 0 1900
63385805 rterte B Oct. 25, 2019, 1:44 p.m. OK Java 8 TESTS 88 155 2969600 1900
59061980 Darth_Jar_Jar_Binks B Aug. 18, 2019, 10:36 p.m. OK Java 8 TESTS 86 155 3072000 1900
59684098 heff10 B Aug. 29, 2019, 11:25 p.m. OK Java 8 TESTS 88 155 3174400 1900
68728169 an09mous B Jan. 13, 2020, 6:44 p.m. OK Java 8 TESTS 88 155 6656000 1900
59381356 eater B Aug. 24, 2019, 3:22 a.m. OK Kotlin TESTS 88 265 8704000 1900
59599427 vjudge4 B Aug. 28, 2019, 4:54 a.m. OK Kotlin TESTS 88 405 9216000 1900
59535132 darnley B Aug. 26, 2019, 4:37 p.m. OK Kotlin TESTS 88 483 20172800 1900
59347792 darnley B Aug. 23, 2019, 10:30 a.m. OK Kotlin TESTS 88 779 82329600 1900
59073249 camypaper B Aug. 19, 2019, 5:55 a.m. OK Mono C# TESTS 87 109 10240000 1900
64155563 vjudge4 B Nov. 3, 2019, 12:42 p.m. OK MS C++ TESTS 88 31 204800 1900
59973412 le_quibbler B Sept. 4, 2019, 3:57 a.m. OK MS C++ TESTS 88 31 716800 1900
66494456 vjudge2 B Dec. 8, 2019, 9:54 a.m. OK MS C++ TESTS 88 31 1740800 1900
59117576 vjudge2 B Aug. 20, 2019, 2:44 a.m. OK MS C++ TESTS 88 46 1126400 1900
63921287 vjudge4 B Oct. 31, 2019, 11:47 a.m. OK MS C++ TESTS 88 46 4812800 1900
59082101 vjudge5 B Aug. 19, 2019, 9:35 a.m. OK MS C++ TESTS 88 108 20992000 1900
59027933 BaturaDima B Aug. 18, 2019, 2:40 p.m. OK MS C++ TESTS 83 139 2355200 1900
59215025 vjudge1 B Aug. 21, 2019, 9:55 a.m. OK MS C++ TESTS 88 155 1126400 1900
66555494 vjudge2 B Dec. 9, 2019, 4:35 p.m. OK MS C++ TESTS 88 155 2252800 1900
59122559 kevin19984 B Aug. 20, 2019, 6:33 a.m. OK MS C++ TESTS 88 202 20787200 1900
66461636 vjudge1 B Dec. 7, 2019, 3 p.m. OK MS C++ 2017 TESTS 88 31 614400 1900
59549771 guoriyue B Aug. 27, 2019, 1:57 a.m. OK MS C++ 2017 TESTS 88 46 307200 1900
66462855 vjudge5 B Dec. 7, 2019, 3:26 p.m. OK MS C++ 2017 TESTS 88 46 614400 1900
59973431 le_quibbler B Sept. 4, 2019, 3:58 a.m. OK MS C++ 2017 TESTS 88 61 716800 1900
63556856 CapNemo B Oct. 27, 2019, 1:07 p.m. OK MS C++ 2017 TESTS 88 78 307200 1900
68128088 vjudge3 B Jan. 3, 2020, 3:57 p.m. OK MS C++ 2017 TESTS 88 78 512000 1900
59112338 dandf B Aug. 19, 2019, 9:49 p.m. OK MS C++ 2017 TESTS 88 93 102400 1900
59023155 Taube B Aug. 18, 2019, 2:26 p.m. OK MS C++ 2017 TESTS 83 156 3993600 1900
59902822 vjudge4 B Sept. 2, 2019, 2:14 p.m. OK MS C++ 2017 TESTS 88 171 17612800 1900
60803334 alanM B Sept. 18, 2019, 5:20 p.m. OK MS C++ 2017 TESTS 88 187 1843200 1900
61251667 Zysonic B Sept. 25, 2019, 8:31 a.m. OK PyPy 2 TESTS 88 156 16384000 1900
66417397 codershuvo B Dec. 6, 2019, 5:36 p.m. OK PyPy 3 TESTS 88 327 16691200 1900
60392407 drinkwaterknow B Sept. 11, 2019, 1:45 p.m. OK PyPy 3 TESTS 88 358 13414400 1900
59219860 Lina_Inverse B Aug. 21, 2019, 11:50 a.m. OK PyPy 3 TESTS 88 374 19353600 1900
60046336 nagato1208 B Sept. 4, 2019, 8:38 p.m. OK PyPy 3 TESTS 88 405 13414400 1900
59086853 psint B Aug. 19, 2019, 11:21 a.m. OK PyPy 3 TESTS 88 420 14540800 1900
59981751 nagato1208 B Sept. 4, 2019, 8:42 a.m. OK PyPy 3 TESTS 88 421 13414400 1900
61365018 satyamcse B Sept. 27, 2019, 1:15 p.m. OK PyPy 3 TESTS 88 421 34304000 1900
60236215 smart_hard B Sept. 7, 2019, 6:35 p.m. OK PyPy 3 TESTS 88 624 50278400 1900
65269352 jdbermeol B Nov. 17, 2019, 6:49 p.m. OK PyPy 3 TESTS 88 686 49561600 1900
68460138 Firepaw B Jan. 9, 2020, 5:46 p.m. OK PyPy 3 TESTS 88 701 20480000 1900
68985686 anshuman16423 B Jan. 17, 2020, 12:24 p.m. OK Python 2 TESTS 88 998 20684800 1900
59128717 Maripium B Aug. 20, 2019, 10:06 a.m. OK Python 3 TESTS 88 186 10137600 1900
59128870 Lancern B Aug. 20, 2019, 10:10 a.m. OK Rust TESTS 88 31 2457600 1900
59377032 ValenKof B Aug. 23, 2019, 10:53 p.m. OK Rust TESTS 88 93 22220800 1900
59054577 limed B Aug. 18, 2019, 6:26 p.m. OK Scala TESTS 85 576 6041600 1900

remove filters

Back to search problems