Codeforces Round 715 (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
1508 Codeforces Round 715 (Div. 1) FINISHED False 8100 113239499 April 16, 2021, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 1513 ) C Complete the MST PROGRAMMING data structures dfs and similar ds graphs greedy math

B"As a teacher, Riko Hakozaki often needs to help her students with problems from various subjects. Today, she is asked a programming task which goes as follows. You are given an undirected complete graph with n nodes, where some edges are pre-assigned with a positive weight while the rest aren't. You need to assign all unassigned edges with non-negative weights so that in the resulting fully-assigned complete graph the XOR sum of all weights would be equal to 0 . Define the ugliness of a fully-assigned complete graph the weight of its minimum spanning tree, where the weight of a spanning tree equals the sum of weights of its edges. You need to assign the weights so that the ugliness of the resulting graph is as small as possible. As a reminder, an undirected complete graph with n nodes contains all edges (u, v) with 1 <= u < v <= n ; such a graph has frac{n(n-1)}{2} edges. She is not sure how to solve this problem, so she asks you to solve it for her. The first line contains two integers n and m ( 2 <= n <= 2 cdot 10^5 , 0 <= m <= min(2 cdot 10^5, frac{n(n-1)}{2} - 1) ) -- the number of nodes and the number of pre-assigned edges. The inputs are given so that there is at least one unassigned edge. The i -th of the following m lines contains three integers u_i , v_i , and w_i ( 1 <= u_i, v_i <= n , u ne v , 1 <= w_i < 2^{30} ), representing the edge from u_i to v_i has been pre-assigned with the weight w_i . No edge appears in the input more than once. Print on one line one integer -- the minimum ugliness among all weight assignments with XOR sum equal to 0 . The following image showcases the first test case. The black weights are pre-assigned from the statement, the red weights are assigned by us, and the minimum spanning tree is denoted by the blue edges. "...

Tutorials

Codeforces Round #715 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
113279188 rainboy C April 16, 2021, 10:46 p.m. OK GNU C11 TESTS 29 218 26931200
113252775 liuhengxi C April 16, 2021, 4:40 p.m. OK GNU C++11 TESTS 28 78 33382400
113283770 SevenDawns C April 17, 2021, 1:39 a.m. OK GNU C++11 TESTS 29 124 37478400
113254426 Mitsukasa_Ayase C April 16, 2021, 4:45 p.m. OK GNU C++11 TESTS 28 124 56217600
113241611 yzc2005 C April 16, 2021, 4:09 p.m. OK GNU C++11 TESTS 28 124 241356800
113281862 Mr_Eight C April 17, 2021, 12:27 a.m. OK GNU C++11 TESTS 29 171 51404800
113242861 basic_string C April 16, 2021, 4:13 p.m. OK GNU C++11 TESTS 28 171 73625600
113289255 xyf007 C April 17, 2021, 3:50 a.m. OK GNU C++11 TESTS 29 187 28876800
113220606 duality C April 16, 2021, 3:21 p.m. OK GNU C++11 TESTS 28 218 31027200
113250529 nantf C April 16, 2021, 4:34 p.m. OK GNU C++11 TESTS 28 280 49971200
113295932 Acranker C April 17, 2021, 5:42 a.m. OK GNU C++11 TESTS 29 343 50688000
113249329 Zetr0 C April 16, 2021, 4:30 p.m. OK GNU C++14 TESTS 28 218 23654400
113236729 al3xstr33t C April 16, 2021, 3:57 p.m. OK GNU C++14 TESTS 28 234 27545600
113281521 AhoCorasick C April 17, 2021, 12:13 a.m. OK GNU C++14 TESTS 29 249 15872000
113255913 George1123 C April 16, 2021, 4:48 p.m. OK GNU C++14 TESTS 28 280 17100800
113267289 SuperJ6 C April 16, 2021, 6:48 p.m. OK GNU C++14 TESTS 28 295 29286400
113269563 TheOneYouWant C April 16, 2021, 7:23 p.m. OK GNU C++14 TESTS 28 296 22323200
113228049 dlalswp25 C April 16, 2021, 3:36 p.m. OK GNU C++14 TESTS 28 296 26931200
113270584 Kaitokid C April 16, 2021, 7:39 p.m. OK GNU C++14 TESTS 28 327 38195200
113235696 Noam527 C April 16, 2021, 3:54 p.m. OK GNU C++14 TESTS 28 358 31539200
113245309 AdelShakal C April 16, 2021, 4:19 p.m. OK GNU C++14 TESTS 28 358 33484800
113230097 izone C April 16, 2021, 3:41 p.m. OK GNU C++17 TESTS 28 156 58880000
113243654 gmh77 C April 16, 2021, 4:15 p.m. OK GNU C++17 TESTS 28 171 13824000
113237480 p6pou C April 16, 2021, 3:59 p.m. OK GNU C++17 TESTS 28 202 12595200
113231290 RAVEman C April 16, 2021, 3:44 p.m. OK GNU C++17 TESTS 28 202 15564800
113225959 yhx-12243 C April 16, 2021, 3:32 p.m. OK GNU C++17 TESTS 28 217 18841600
113273060 AliShahali1382 C April 16, 2021, 8:18 p.m. OK GNU C++17 TESTS 28 218 12902400
113228228 AghaSeyed C April 16, 2021, 3:37 p.m. OK GNU C++17 TESTS 28 218 12902400
113266068 zerotrac C April 16, 2021, 6:31 p.m. OK GNU C++17 TESTS 28 233 15155200
113271460 yfhuang C April 16, 2021, 7:52 p.m. OK GNU C++17 TESTS 28 233 29696000
113280853 jeroenodb C April 16, 2021, 11:46 p.m. OK GNU C++17 TESTS 29 248 33280000
113281758 Mivik C April 17, 2021, 12:23 a.m. OK GNU C++17 (64) TESTS 29 124 31232000
113256108 Hyperbolic C April 16, 2021, 4:48 p.m. OK GNU C++17 (64) TESTS 28 140 27033600
113281611 Mivik C April 17, 2021, 12:17 a.m. OK GNU C++17 (64) TESTS 29 155 30720000
113226477 heno239 C April 16, 2021, 3:33 p.m. OK GNU C++17 (64) TESTS 28 171 17100800
113260291 Archer_ C April 16, 2021, 5:29 p.m. OK GNU C++17 (64) TESTS 28 171 22118400
113255540 ollpu C April 16, 2021, 4:47 p.m. OK GNU C++17 (64) TESTS 28 202 16793600
113247593 Rubikun C April 16, 2021, 4:26 p.m. OK GNU C++17 (64) TESTS 28 202 20172800
113237338 emthrm C April 16, 2021, 3:58 p.m. OK GNU C++17 (64) TESTS 28 217 23040000
113246053 hzkmd C April 16, 2021, 4:21 p.m. OK GNU C++17 (64) TESTS 28 218 13107200
113215542 Petr C April 16, 2021, 3:12 p.m. OK GNU C++17 (64) TESTS 28 218 15257600
113265788 Hasan0540 C April 16, 2021, 6:27 p.m. OK Go TESTS 28 514 19968000
113265981 Hasan0540 C April 16, 2021, 6:29 p.m. OK Go TESTS 28 545 20070400
113265517 Hasan0540 C April 16, 2021, 6:23 p.m. OK Go TESTS 28 576 19968000
113235853 uwi C April 16, 2021, 3:55 p.m. OK Java 11 TESTS 28 608 16281600
113275005 TheSawan C April 16, 2021, 8:52 p.m. OK Java 8 TESTS 28 702 56832000
113250883 iakovlev.zakhar C April 16, 2021, 4:35 p.m. OK Java 8 TESTS 28 904 115916800
113268425 YahiaSherif C April 16, 2021, 7:06 p.m. OK Java 8 TESTS 28 935 77209600
113268224 YahiaSherif C April 16, 2021, 7:03 p.m. OK Java 8 TESTS 28 935 77312000
113268253 YahiaSherif C April 16, 2021, 7:03 p.m. OK Java 8 TESTS 28 936 77312000
113265967 YahiaSherif C April 16, 2021, 6:29 p.m. OK Java 8 TESTS 28 982 77209600
113268310 YahiaSherif C April 16, 2021, 7:04 p.m. OK Java 8 TESTS 28 982 77312000
113251308 fetetriste C April 16, 2021, 4:36 p.m. OK Java 8 TESTS 28 1185 86016000
113239726 dalt C April 16, 2021, 4:04 p.m. OK Java 8 TESTS 28 1279 110796800
113249667 uttfuczmuo C April 16, 2021, 4:31 p.m. OK MS C++ 2017 TESTS 28 1154 61440000
113273209 Arnyev C April 16, 2021, 8:20 p.m. OK .NET Core C# TESTS 28 514 59084800
113250330 chinerist C April 16, 2021, 4:33 p.m. OK PyPy 3 TESTS 28 1403 95232000
113246313 SPD_9X2 C April 16, 2021, 4:22 p.m. OK PyPy 3 TESTS 28 1591 50688000
113227417 sansen C April 16, 2021, 3:35 p.m. OK Rust TESTS 28 155 26112000
113289038 sansen C April 17, 2021, 3:46 a.m. OK Rust TESTS 29 155 28160000
113260053 toomer C April 16, 2021, 5:27 p.m. OK Rust TESTS 28 218 25395200

remove filters

Back to search problems