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 |
---|---|---|---|---|---|---|
487 | Codeforces Round 278 (Div. 1) | FINISHED | False | 7200 | 315232799 | Nov. 21, 2014, 5:20 p.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 2380 ) | E | Tourists | PROGRAMMING | data structures dfs and similar graphs trees | 3100 |
B'There are n cities in Cyberland, numbered from 1 to n, connected by m bidirectional roads. The j-th road connects city aj and bj. For tourists, souvenirs are sold in every city of Cyberland. In particular, city i sell it at a price of wi. Now there are q queries for you to handle. There are two types of queries: More formally, we can define routes as follow: The first line of input contains three integers n, xe2 x80 x89m, xe2 x80 x89q (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n, xe2 x80 x89m, xe2 x80 x89q xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89105), separated by a single space. Next n lines contain integers wi (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89wi xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89109). Next m lines contain pairs of space-separated integers aj and bj (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89aj, xe2 x80 x89bj xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n, xe2 x80 x89aj xe2 x80 x89 xe2 x89 xa0 xe2 x80 x89bj). It is guaranteed that there is at most one road connecting the same pair of cities. There is always at least one valid route between any two cities. Next q lines each describe a query. The format is "C a w" or "A a b" (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89a, xe2 x80 x89b xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n, xe2 x80 x891 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89w xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89109). For each query of type "A", output the corresponding answer. For the second sample, an optimal routes are: From 2 to 3 it is [2, xe2 x80 x893]. From 6 to 4 it is [6, xe2 x80 x895, xe2 x80 x891, xe2 x80 x892, xe2 x80 x894]. From 6 to 7 it is [6, xe2 x80 x895, xe2 x80 x897]. From 3 to 3 it is [3].'... |
Tutorial |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
15515784 | immortalCO | E | Jan. 23, 2016, 2:39 p.m. | OK | GNU C++ | TESTS | 58 | 93 | 40038400 | 3100 | |
15515834 | immortalCO | E | Jan. 23, 2016, 2:43 p.m. | OK | GNU C++ | TESTS | 58 | 108 | 38502400 | 3100 | |
40987668 | ReaLNero1 | E | July 30, 2018, 9:24 p.m. | OK | GNU C++ | TESTS | 58 | 109 | 38502400 | 3100 | |
35666128 | luogu_bot1 | E | Feb. 25, 2018, 2:17 a.m. | OK | GNU C++ | TESTS | 58 | 140 | 63590400 | 3100 | |
35666313 | luogu_bot2 | E | Feb. 25, 2018, 2:31 a.m. | OK | GNU C++ | TESTS | 58 | 155 | 63590400 | 3100 | |
16626913 | Memory120 | E | March 10, 2016, 4:02 a.m. | OK | GNU C++ | TESTS | 58 | 156 | 34918400 | 3100 | |
35672421 | Cyhlnj | E | Feb. 25, 2018, 8:22 a.m. | OK | GNU C++ | TESTS | 58 | 156 | 63590400 | 3100 | |
35666273 | luogu_bot1 | E | Feb. 25, 2018, 2:28 a.m. | OK | GNU C++ | TESTS | 58 | 156 | 63590400 | 3100 | |
27441567 | LCF | E | May 30, 2017, 6:55 a.m. | OK | GNU C++ | TESTS | 58 | 170 | 38502400 | 3100 | |
41123318 | vjudge5 | E | Aug. 2, 2018, 1:03 p.m. | OK | GNU C++ | TESTS | 58 | 171 | 138035200 | 3100 | |
10039300 | Remilia-Scarlet | E | Feb. 27, 2015, 2:26 a.m. | OK | GNU C++0x | TESTS | 58 | 233 | 70553600 | 3100 | |
9536118 | liuzhuo | E | Jan. 24, 2015, 9:04 a.m. | OK | GNU C++0x | TESTS | 58 | 296 | 65945600 | 3100 | |
9538337 | liuzhuo | E | Jan. 24, 2015, 1:02 p.m. | OK | GNU C++0x | TESTS | 58 | 311 | 63590400 | 3100 | |
9421847 | zhj | E | Jan. 13, 2015, 7:13 a.m. | OK | GNU C++0x | TESTS | 58 | 327 | 70041600 | 3100 | |
8805270 | Nero | E | Nov. 22, 2014, 5:45 p.m. | OK | GNU C++0x | TESTS | 58 | 358 | 51507200 | 3100 | |
8837715 | Rivx | E | Nov. 24, 2014, 3:40 p.m. | OK | GNU C++0x | TESTS | 58 | 373 | 54374400 | 3100 | |
8867465 | yummy | E | Nov. 27, 2014, 8:45 a.m. | OK | GNU C++0x | TESTS | 58 | 374 | 44339200 | 3100 | |
8787144 | anta | E | Nov. 21, 2014, 6:51 p.m. | OK | GNU C++0x | TESTS | 58 | 499 | 53248000 | 3100 | |
8951491 | T0RRES | E | Dec. 3, 2014, 11:49 a.m. | OK | GNU C++0x | TESTS | 58 | 530 | 98918400 | 3100 | |
8951376 | T0RRES | E | Dec. 3, 2014, 11:40 a.m. | OK | GNU C++0x | TESTS | 58 | 530 | 98918400 | 3100 | |
41641279 | temp6 | E | Aug. 16, 2018, 5:42 a.m. | OK | GNU C++11 | TESTS | 58 | 108 | 97587200 | 3100 | |
41641255 | temp6 | E | Aug. 16, 2018, 5:41 a.m. | OK | GNU C++11 | TESTS | 58 | 109 | 97587200 | 3100 | |
41813824 | luogu_bot2 | E | Aug. 19, 2018, 5:22 a.m. | OK | GNU C++11 | TESTS | 58 | 124 | 55296000 | 3100 | |
30492507 | ditoly | E | Sept. 19, 2017, 9:26 a.m. | OK | GNU C++11 | TESTS | 58 | 140 | 29286400 | 3100 | |
51415887 | lwhlwh | E | March 17, 2019, 2 p.m. | OK | GNU C++11 | TESTS | 58 | 140 | 31846400 | 3100 | |
64894302 | boy_devil | E | Nov. 14, 2019, 3:56 p.m. | OK | GNU C++11 | TESTS | 58 | 155 | 31846400 | 3100 | |
43628383 | GKxx | E | Oct. 1, 2018, 2:32 a.m. | OK | GNU C++11 | TESTS | 58 | 155 | 36044800 | 3100 | |
55116338 | luogu_bot3 | E | June 5, 2019, 8:50 a.m. | OK | GNU C++11 | TESTS | 58 | 155 | 38502400 | 3100 | |
41813573 | luogu_bot4 | E | Aug. 19, 2018, 5:12 a.m. | OK | GNU C++11 | TESTS | 58 | 155 | 45260800 | 3100 | |
45191371 | luogu_bot1 | E | Nov. 2, 2018, 2:38 a.m. | OK | GNU C++11 | TESTS | 58 | 156 | 35328000 | 3100 | |
27537659 | Gintoki | E | June 3, 2017, 6:41 a.m. | OK | GNU C++14 | TESTS | 58 | 218 | 93491200 | 3100 | |
67190149 | Paulliant | E | Dec. 19, 2019, 6:44 a.m. | OK | GNU C++14 | TESTS | 58 | 264 | 38604800 | 3100 | |
25767325 | q234rty | E | March 24, 2017, 9:03 a.m. | OK | GNU C++14 | TESTS | 58 | 280 | 77721600 | 3100 | |
41124147 | Taizong | E | Aug. 2, 2018, 1:26 p.m. | OK | GNU C++14 | TESTS | 58 | 295 | 57446400 | 3100 | |
67270002 | ElangBondol | E | Dec. 20, 2019, 7:48 a.m. | OK | GNU C++14 | TESTS | 58 | 296 | 38604800 | 3100 | |
67183316 | Paulliant | E | Dec. 19, 2019, 2:13 a.m. | OK | GNU C++14 | TESTS | 58 | 296 | 39116800 | 3100 | |
37573584 | NKstarkmal | E | April 24, 2018, 1:19 p.m. | OK | GNU C++14 | TESTS | 58 | 296 | 49254400 | 3100 | |
51582204 | TadijaSebez | E | March 20, 2019, 2:52 p.m. | OK | GNU C++14 | TESTS | 58 | 311 | 28876800 | 3100 | |
68091333 | Dormi | E | Jan. 2, 2020, 6:16 p.m. | OK | GNU C++14 | TESTS | 58 | 311 | 48742400 | 3100 | |
53216077 | dsl2002 | E | April 24, 2019, 8:51 a.m. | OK | GNU C++14 | TESTS | 58 | 311 | 51302400 | 3100 | |
41621899 | temp6 | E | Aug. 15, 2018, 12:22 p.m. | OK | GNU C++17 | TESTS | 58 | 108 | 81817600 | 3100 | |
41621449 | temp6 | E | Aug. 15, 2018, 12:11 p.m. | OK | GNU C++17 | TESTS | 58 | 124 | 81817600 | 3100 | |
54221914 | nickluo | E | May 16, 2019, 3:56 a.m. | OK | GNU C++17 | TESTS | 58 | 202 | 67788800 | 3100 | |
44401504 | cxt | E | Oct. 16, 2018, 12:59 p.m. | OK | GNU C++17 | TESTS | 58 | 234 | 31436800 | 3100 | |
44394552 | zhaimingshuzms | E | Oct. 16, 2018, 10:06 a.m. | OK | GNU C++17 | TESTS | 58 | 249 | 36761600 | 3100 | |
65412558 | 2qbingxuan | E | Nov. 20, 2019, 5:10 a.m. | OK | GNU C++17 | TESTS | 58 | 265 | 45875200 | 3100 | |
41621668 | temp6 | E | Aug. 15, 2018, 12:16 p.m. | OK | GNU C++17 | TESTS | 58 | 265 | 81817600 | 3100 | |
66487862 | vjudge2 | E | Dec. 8, 2019, 7:17 a.m. | OK | GNU C++17 | TESTS | 58 | 280 | 44236800 | 3100 | |
65411626 | 2qbingxuan | E | Nov. 20, 2019, 4:37 a.m. | OK | GNU C++17 | TESTS | 58 | 280 | 45875200 | 3100 | |
49856796 | nekko | E | Feb. 13, 2019, 7:37 a.m. | OK | GNU C++17 | TESTS | 58 | 280 | 102502400 | 3100 | |
42261135 | nchn27 | E | Aug. 30, 2018, 3:18 a.m. | OK | Java 8 | TESTS | 58 | 1388 | 186368000 | 3100 | |
14225408 | Ruins | E | Nov. 13, 2015, 11:19 a.m. | OK | Java 8 | TESTS | 58 | 1871 | 224768000 | 3100 | |
56864081 | vjudge2 | E | July 12, 2019, 1:50 a.m. | OK | MS C++ | TESTS | 58 | 405 | 42700800 | 3100 | |
22572208 | Taube | E | Nov. 28, 2016, 11:41 a.m. | OK | MS C++ | TESTS | 58 | 467 | 42393600 | 3100 | |
48641399 | vjudge2 | E | Jan. 20, 2019, 3:32 p.m. | OK | MS C++ | TESTS | 58 | 468 | 46387200 | 3100 | |
53813229 | LAUV | E | May 6, 2019, 8:27 a.m. | OK | MS C++ 2017 | TESTS | 58 | 358 | 37683200 | 3100 |
Back to search problems