Codeforces Round 636 (Div. 3)

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
1343 Codeforces Round 636 (Div. 3) FINISHED False 7200 149700263 April 21, 2020, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 5267 ) E Weights Distributing PROGRAMMING brute force graphs greedy shortest paths sortings 2400

B"You are given an undirected unweighted graph consisting of n vertices and m edges (which represents the map of Bertown) and the array of prices p of length m . It is guaranteed that there is a path between each pair of vertices (districts). Mike has planned a trip from the vertex (district) a to the vertex (district) b and then from the vertex (district) b to the vertex (district) c . He can visit the same district twice or more. But there is one issue: authorities of the city want to set a price for using the road so if someone goes along the road then he should pay the price corresponding to this road (he pays each time he goes along the road). The list of prices that will be used p is ready and they just want to distribute it between all roads in the town in such a way that each price from the array corresponds to exactly one road. You are a good friend of Mike (and suddenly a mayor of Bertown) and want to help him to make his trip as cheap as possible. So, your task is to distribute prices between roads in such a way that if Mike chooses the optimal path then the price of the trip is the minimum possible. Note that you cannot rearrange prices after the start of the trip. You have to answer t independent test cases. The first line of the input contains one integer t ( 1 <= t <= 10^4 ) -- the number of test cases. Then t test cases follow. The first line of the test case contains five integers n, m, a, b and c ( 2 <= n <= 2 cdot 10^5 , n-1 <= m <= min( frac{n(n-1)}{2}, 2 cdot 10^5) , 1 <= a, b, c <= n ) -- the number of vertices, the number of edges and districts in Mike's trip. The second line of the test case contains m integers p_1, p_2, ... , p_m ( 1 <= p_i <= 10^9 ), where p_i is the i -th price from the array. The following m lines of the test case denote edges: edge i is represented by a pair of "...

Tutorials

76352

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
77756815 N00Borz E April 23, 2020, 1:22 p.m. OK Clang++17 Diagnostics TESTS 43 951 34713600 2400
77571121 daut-dlang E April 21, 2020, 4:51 p.m. OK D TESTS 43 420 37990400 2400
77562407 rainboy E April 21, 2020, 4:27 p.m. OK GNU C11 TESTS 43 171 9830400 2400
77572958 Beku.sh E April 21, 2020, 5:05 p.m. OK GNU C11 TESTS 43 186 9830400 2400
77705172 Feng E April 23, 2020, 2:17 a.m. OK GNU C++11 TESTS 43 78 9216000 2400
77663237 Thomasguo666 E April 22, 2020, 2:56 p.m. OK GNU C++11 TESTS 43 78 37171200 2400
77625658 ticmis E April 22, 2020, 9 a.m. OK GNU C++11 TESTS 43 93 10752000 2400
77638751 wygz E April 22, 2020, 11:23 a.m. OK GNU C++11 TESTS 43 93 11264000 2400
77581976 wang9897 E April 21, 2020, 6:43 p.m. OK GNU C++11 TESTS 43 108 20377600 2400
77574578 suxxsfe E April 21, 2020, 5:19 p.m. OK GNU C++11 TESTS 43 109 17920000 2400
77657849 Angel_Demon E April 22, 2020, 2:08 p.m. OK GNU C++11 TESTS 43 124 11878400 2400
77626027 QieziMin E April 22, 2020, 9:04 a.m. OK GNU C++11 TESTS 43 124 12697600 2400
77574092 suxxsfe E April 21, 2020, 5:15 p.m. OK GNU C++11 TESTS 43 139 17920000 2400
77648205 wasa855 E April 22, 2020, 1:01 p.m. OK GNU C++11 TESTS 43 140 16076800 2400
77732276 fa_555 E April 23, 2020, 9:15 a.m. OK GNU C++14 TESTS 43 93 11366400 2400
77681140 kkqq E April 22, 2020, 5:47 p.m. OK GNU C++14 TESTS 43 171 10137600 2400
77704855 vjudge1 E April 23, 2020, 2:05 a.m. OK GNU C++14 TESTS 43 202 11776000 2400
77585576 _HossamYehia_ E April 21, 2020, 7:34 p.m. OK GNU C++14 TESTS 43 202 17305600 2400
77705459 taarasinh E April 23, 2020, 2:26 a.m. OK GNU C++14 TESTS 43 217 11776000 2400
77695485 dev_rastogi E April 22, 2020, 9:02 p.m. OK GNU C++14 TESTS 43 217 12595200 2400
77621408 aakshu E April 22, 2020, 8:13 a.m. OK GNU C++14 TESTS 43 218 12595200 2400
77703315 CECI_07 E April 23, 2020, 1:13 a.m. OK GNU C++14 TESTS 43 218 12595200 2400
77756315 Laith_Drebaty E April 23, 2020, 1:16 p.m. OK GNU C++14 TESTS 43 218 12595200 2400
77972468 OTTFF E April 25, 2020, 3:52 a.m. OK GNU C++14 TESTS 43 218 12800000 2400
77864547 _andyli E April 24, 2020, 1:13 a.m. OK GNU C++17 TESTS 43 78 13516800 2400
77715113 Maybach E April 23, 2020, 5:34 a.m. OK GNU C++17 TESTS 43 171 11161600 2400
77704881 lighting_kissing E April 23, 2020, 2:06 a.m. OK GNU C++17 TESTS 43 187 11776000 2400
77662783 jintiandun E April 22, 2020, 2:52 p.m. OK GNU C++17 TESTS 43 187 17612800 2400
77601411 zzs99828 E April 22, 2020, 2:18 a.m. OK GNU C++17 TESTS 43 202 11776000 2400
77757506 _dekri_ E April 23, 2020, 1:29 p.m. OK GNU C++17 TESTS 43 202 12595200 2400
77869810 huangda_ E April 24, 2020, 3:17 a.m. OK GNU C++17 TESTS 43 217 9011200 2400
77656481 gladgeek E April 22, 2020, 1:55 p.m. OK GNU C++17 TESTS 43 217 12595200 2400
77865209 penguinhacker E April 24, 2020, 1:33 a.m. OK GNU C++17 TESTS 43 217 12595200 2400
77673282 sakib_muhit E April 22, 2020, 4:27 p.m. OK GNU C++17 TESTS 43 217 13619200 2400
77605779 liouzhou_101 E April 22, 2020, 4:11 a.m. OK GNU C++17 (64) TESTS 43 124 25088000 2400
77712341 inszva E April 23, 2020, 4:46 a.m. OK GNU C++17 (64) TESTS 43 139 23040000 2400
77899776 ivan100sic E April 24, 2020, 9:44 a.m. OK GNU C++17 (64) TESTS 43 171 15974400 2400
77629405 hltk E April 22, 2020, 9:43 a.m. OK GNU C++17 (64) TESTS 43 186 15360000 2400
77691531 trungams E April 22, 2020, 7:55 p.m. OK GNU C++17 (64) TESTS 43 187 14131200 2400
77758051 Asagami E April 23, 2020, 1:35 p.m. OK GNU C++17 (64) TESTS 43 202 14028800 2400
77648284 ir_1st_vil E April 22, 2020, 1:02 p.m. OK GNU C++17 (64) TESTS 43 202 14131200 2400
77688377 idgaf_99 E April 22, 2020, 7:08 p.m. OK GNU C++17 (64) TESTS 43 202 14233600 2400
77760906 Bondo E April 23, 2020, 1:55 p.m. OK GNU C++17 (64) TESTS 43 202 14950400 2400
78005595 masayoshi64 E April 25, 2020, 9:03 a.m. OK GNU C++17 (64) TESTS 43 202 14950400 2400
77570060 synapse E April 21, 2020, 4:45 p.m. OK Go TESTS 43 530 24064000 2400
77917129 Piccadilly E April 24, 2020, 1:43 p.m. OK Java 11 TESTS 43 389 9216000 2400
77918935 Piccadilly E April 24, 2020, 1:57 p.m. OK Java 11 TESTS 43 436 23552000 2400
77604984 jenish9599 E April 22, 2020, 3:52 a.m. OK Java 11 TESTS 43 576 45363200 2400
77628468 sarthakmanna E April 22, 2020, 9:32 a.m. OK Java 11 TESTS 43 608 42086400 2400
77646750 avijit_agarwal E April 22, 2020, 12:46 p.m. OK Java 11 TESTS 43 654 54886400 2400
77633238 idk321 E April 22, 2020, 10:26 a.m. OK Java 11 TESTS 43 717 48128000 2400
77658774 Tatsuyaaaa E April 22, 2020, 2:16 p.m. OK Java 11 TESTS 43 733 48640000 2400
77570001 nsmikhailov E April 21, 2020, 4:45 p.m. OK Java 11 TESTS 43 748 59494400 2400
77739182 bhautik_77 E April 23, 2020, 10:21 a.m. OK Java 11 TESTS 43 748 72396800 2400
77691449 mikkk E April 22, 2020, 7:53 p.m. OK Java 11 TESTS 43 763 48230400 2400
77592601 NMouad21 E April 21, 2020, 9:41 p.m. OK Java 8 TESTS 43 264 17612800 2400
77775394 prashanth21992 E April 23, 2020, 2:53 p.m. OK Java 8 TESTS 43 498 50073600 2400
77563344 aminul E April 21, 2020, 4:28 p.m. OK Java 8 TESTS 43 514 39219200 2400
77654971 yash49 E April 22, 2020, 1:40 p.m. OK Java 8 TESTS 43 514 53760000 2400
77674065 amolpratap007 E April 22, 2020, 4:34 p.m. OK Java 8 TESTS 43 545 49152000 2400
77572840 ShesMyNerd E April 21, 2020, 5:04 p.m. OK Java 8 TESTS 43 560 55808000 2400
77691872 nandit E April 22, 2020, 8 p.m. OK Java 8 TESTS 43 560 57651200 2400
77664168 Nirav E April 22, 2020, 3:05 p.m. OK Java 8 TESTS 43 561 39424000 2400
77573394 icpc_loser E April 21, 2020, 5:09 p.m. OK Java 8 TESTS 43 576 60825600 2400
77756414 dewanshnigam E April 23, 2020, 1:17 p.m. OK Java 8 TESTS 43 608 62054400 2400
77557890 avm E April 21, 2020, 4:18 p.m. OK Kotlin TESTS 43 280 7884800 2400
77606245 Spheniscine E April 22, 2020, 4:21 a.m. OK Kotlin TESTS 43 483 31539200 2400
77677367 Kopenkin E April 22, 2020, 5:07 p.m. OK Kotlin TESTS 43 826 53657600 2400
77557970 koboshi E April 21, 2020, 4:19 p.m. OK Kotlin TESTS 43 1372 117964800 2400
77655820 artworks E April 22, 2020, 1:49 p.m. OK Mono C# TESTS 43 561 36659200 2400
77573816 Yupiteru E April 21, 2020, 5:12 p.m. OK Mono C# TESTS 43 872 55808000 2400
77763508 pikachan14 E April 23, 2020, 2:16 p.m. OK MS C++ 2017 TESTS 43 280 13107200 2400
77587782 AleksanderBalobanov E April 21, 2020, 8:10 p.m. OK MS C++ 2017 TESTS 43 296 41676800 2400
77606405 DmitryZ E April 22, 2020, 4:24 a.m. OK MS C++ 2017 TESTS 43 546 12288000 2400
77721931 0Mordecai0 E April 23, 2020, 7:07 a.m. OK MS C++ 2017 TESTS 43 608 13824000 2400
77585560 danilgrig E April 21, 2020, 7:34 p.m. OK MS C++ 2017 TESTS 43 623 12390400 2400
77573792 mihaiI E April 21, 2020, 5:12 p.m. OK MS C++ 2017 TESTS 43 639 12288000 2400
77570965 not_antony E April 21, 2020, 4:51 p.m. OK MS C++ 2017 TESTS 43 686 13209600 2400
77574252 realnimish E April 21, 2020, 5:16 p.m. OK PyPy 2 TESTS 43 763 50995200 2400
77572212 SlowDecay E April 21, 2020, 4:59 p.m. OK PyPy 2 TESTS 43 997 39219200 2400
77645409 qwertz73355a E April 22, 2020, 12:32 p.m. OK PyPy 3 TESTS 43 701 65228800 2400
77680984 amogh17009 E April 22, 2020, 5:45 p.m. OK PyPy 3 TESTS 43 888 84172800 2400
77717117 amogh17009 E April 23, 2020, 6:03 a.m. OK PyPy 3 TESTS 43 904 83558400 2400
77603336 UD_xlinsist E April 22, 2020, 3:14 a.m. OK PyPy 3 TESTS 43 998 42803200 2400
77658582 kunal_magnetic E April 22, 2020, 2:14 p.m. OK PyPy 3 TESTS 43 1044 50892800 2400
77578613 FireBird23 E April 21, 2020, 6:02 p.m. OK PyPy 3 TESTS 43 1076 117862400 2400
77570312 neterukun E April 21, 2020, 4:47 p.m. OK PyPy 3 TESTS 43 1091 55808000 2400
77646149 Munchy_1 E April 22, 2020, 12:39 p.m. OK PyPy 3 TESTS 43 1092 53452800 2400
77700832 jay__0208 E April 22, 2020, 11:32 p.m. OK PyPy 3 TESTS 43 1107 50995200 2400
77733591 roaris E April 23, 2020, 9:31 a.m. OK PyPy 3 TESTS 43 1138 39628800 2400
77597611 mkawa2 E April 22, 2020, 12:21 a.m. OK Python 3 TESTS 43 1216 47001600 2400
77747380 prabakar.rangarajan E April 23, 2020, 11:46 a.m. OK Python 3 TESTS 43 1465 44236800 2400
77902118 learner7321 E April 24, 2020, 10:30 a.m. OK Python 3 TESTS 43 1637 49971200 2400
77748109 prabakar.rangarajan E April 23, 2020, 11:51 a.m. OK Python 3 TESTS 43 1715 43724800 2400
78012386 dragosv E April 25, 2020, 10:19 a.m. OK Python 3 TESTS 43 1856 43929600 2400
78011815 dragosv E April 25, 2020, 10:13 a.m. OK Python 3 TESTS 43 1856 43929600 2400
78011713 dragosv E April 25, 2020, 10:12 a.m. OK Python 3 TESTS 43 1949 43929600 2400
78012696 dragosv E April 25, 2020, 10:22 a.m. OK Python 3 TESTS 43 1980 43929600 2400
77581676 rustafarian E April 21, 2020, 6:39 p.m. OK Rust TESTS 43 295 14540800 2400
77576062 rustafarian E April 21, 2020, 5:33 p.m. OK Rust TESTS 43 295 14540800 2400
77581722 rustafarian E April 21, 2020, 6:40 p.m. OK Rust TESTS 43 296 14540800 2400
77570010 limed E April 21, 2020, 4:45 p.m. OK Scala TESTS 43 1107 73830400 2400

remove filters

Back to search problems