2021-2022 ICPC, NERC, Northern Eurasia Onsite (Unrated, Online Mirror, ICPC Rules, Teams Preferred)

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
1666 2021-2022 ICPC, NERC, Northern Eurasia Onsite (Unrated, Online Mirror, ICPC Rules, Teams Preferred) FINISHED False 18000 81986099 April 13, 2022, 8:05 a.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 251 ) K Kingdom Partition PROGRAMMING

B"The King is gone. After the King's rule, all the roads in the Kingdom are run down and need repair. Three of the King's children, Adrian, Beatrice and Cecilia, are dividing the Kingdom between themselves. Adrian and Beatrice do not like each other and do not plan to maintain any relations between themselves in the future. Cecilia is on good terms with both of them. Moreover, most of the Kingdom's workers support Cecilia, so she has better resources and more opportunity to repair the infrastructure and develop the economy. Cecilia proposes to partition the Kingdom into three districts: A (for Adrian), B (for Beatrice), and C (for Cecilia), and let Adrian and Beatrice to negotiate and choose any towns they want to be in their districts, and agree on how they want to partition the Kingdom into three districts. Adrian's castle is located in town a , and Beatrice's one is located in town b . So Adrian and Beatrice want their castles to be located in districts A and B, respectively. Cecilia doesn't have a castle, so district C can consist of no towns. There is an issue for Adrian and Beatrice. When they choose the towns, they will have to pay for the roads' repair. The cost to repair the road of length l is 2l gold. However, Adrian and Beatrice don't have to bear all the repair costs. The repair cost for the road of length l that they bear depends on what towns it connects: The roads that connect towns from district A and district B won't be repaired, since Adrian and Beatrice are not planning to use them, so no one pays for them. Cecilia herself will repair the roads that connect the towns inside district C, so Adrian and Beatrice won't bear the cost of their repair either. Adrian and Beatrice want to minimize the total cost they spend on roads' repair. Find the cheapest way for them to partition the Kingdom into three districts. The first line contains two integers n and m -- the number of towns and the number of "...

Tutorials

Tutorial (PDF)

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
153551778 djq_cpp jiangly MiracleFaFa K April 13, 2022, 11:15 a.m. OK GNU C++14 TESTS 57 15 1945600
153566145 geniucos K April 13, 2022, 1:35 p.m. OK GNU C++17 TESTS 57 31 6656000
153559411 Karry5307_AK_NOI2022 K April 13, 2022, 12:36 p.m. OK GNU C++17 TESTS 57 468 5222400
153600518 wcdr K April 14, 2022, 2:03 a.m. OK GNU C++17 (64) TESTS 57 15 409600
153569615 OIerwanhong K April 13, 2022, 2:20 p.m. OK GNU C++17 (64) TESTS 57 15 9625600
153598456 Alan233 K April 14, 2022, 12:50 a.m. OK GNU C++20 (64) TESTS 57 78 409600

remove filters

Back to search problems