Codeforces Round 383 (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
741 Codeforces Round 383 (Div. 1) FINISHED False 7200 250788299 Dec. 6, 2016, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 2807 ) D Arpa’s letter-marked tree and Mehrdad’s Dokhtar-kosh paths PROGRAMMING data structures dfs and similar trees 2700

B'Just in case somebody missed it: we have wonderful girls in Arpa xe2 x80 x99s land. Arpa has a rooted tree (connected acyclic graph) consisting of n vertices. The vertices are numbered 1 through n, the vertex 1 is the root. There is a letter written on each edge of this tree. Mehrdad is a fan of Dokhtar-kosh things. He call a string Dokhtar-kosh, if we can shuffle the characters in string such that it becomes palindrome. He asks Arpa, for each vertex v, what is the length of the longest simple path in subtree of v that form a Dokhtar-kosh string. The first line contains integer n (1 xe2 x80 x89 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89 xe2 x80 x89n xe2 x80 x89 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89 xe2 x80 x895 xc2 xb7105) -- the number of vertices in the tree. (n xe2 x80 x89 xe2 x80 x89- xe2 x80 x89 xe2 x80 x891) lines follow, the i-th of them contain an integer pi xe2 x80 x89+ xe2 x80 x891 and a letter ci xe2 x80 x89+ xe2 x80 x891 (1 xe2 x80 x89 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89 xe2 x80 x89pi xe2 x80 x89+ xe2 x80 x891 xe2 x80 x89 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89 xe2 x80 x89i, ci xe2 x80 x89+ xe2 x80 x891 is lowercase English letter, between a and v, inclusively), that mean that there is an edge between nodes pi xe2 x80 x89+ xe2 x80 x891 and i xe2 x80 x89+ xe2 x80 x891 and there is a letter ci xe2 x80 x89+ xe2 x80 x891 written on this edge. Print n integers. The i-th of them should be the length of the longest simple path in subtree of the i-th vertex that form a Dokhtar-kosh string. '...

Tutorials

Codeforces Round #383 editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
23079335 s34vv1nd D Dec. 18, 2016, 7:51 a.m. OK FPC TESTS 61 1777 62976000 2700
26487562 apt123 D April 19, 2017, 3:46 a.m. OK FPC TESTS 61 2137 51814400 2700
23193878 jkxjkx1031 D Dec. 21, 2016, 8:10 a.m. OK GNU C TESTS 61 1044 69939200 2700
38771924 luogu_bot4 D May 30, 2018, 12:04 p.m. OK GNU C++ TESTS 61 670 82432000 2700
31332356 vjudge5 D Oct. 15, 2017, 7:38 a.m. OK GNU C++ TESTS 61 670 99840000 2700
40568059 Scut82 D July 20, 2018, 6:39 a.m. OK GNU C++ TESTS 61 685 92876800 2700
40624900 dsl2002 D July 22, 2018, 5:17 a.m. OK GNU C++ TESTS 61 686 67379200 2700
32240356 Scut82 D Nov. 12, 2017, 10:18 a.m. OK GNU C++ TESTS 61 686 96972800 2700
32240355 Scut82 D Nov. 12, 2017, 10:18 a.m. OK GNU C++ TESTS 61 686 96972800 2700
40983056 ReaLNero1 D July 30, 2018, 6:42 p.m. OK GNU C++ TESTS 61 701 99840000 2700
40611069 dsl2002 D July 21, 2018, 2:25 p.m. OK GNU C++ TESTS 61 702 78643200 2700
41673921 vjudge2 D Aug. 17, 2018, 6:58 a.m. OK GNU C++ TESTS 61 717 78643200 2700
29826596 Merln D Aug. 27, 2017, 12:38 p.m. OK GNU C++ TESTS 61 717 99840000 2700
47442583 cxcxccx D Dec. 24, 2018, 3:15 a.m. OK GNU C++11 TESTS 61 499 96972800 2700
46835638 changle_cyx D Dec. 10, 2018, 1:54 a.m. OK GNU C++11 TESTS 61 530 96768000 2700
45197661 Captain_Paul D Nov. 2, 2018, 8:10 a.m. OK GNU C++11 TESTS 61 545 88678400 2700
56369812 vjudge3 D July 1, 2019, 2:44 a.m. OK GNU C++11 TESTS 61 561 78848000 2700
62753837 zzy2005 D Oct. 17, 2019, 3:17 a.m. OK GNU C++11 TESTS 61 561 80896000 2700
58048360 vjudge3 D July 31, 2019, 1:27 a.m. OK GNU C++11 TESTS 61 576 76800000 2700
54447443 cschenshuo D May 21, 2019, 12:01 p.m. OK GNU C++11 TESTS 61 576 78848000 2700
56304859 vjudge2 D June 30, 2019, 11:11 a.m. OK GNU C++11 TESTS 61 576 80896000 2700
62563426 fa_555 D Oct. 14, 2019, 12:38 p.m. OK GNU C++11 TESTS 61 577 80691200 2700
47893680 luogu_bot4 D Jan. 4, 2019, 8:45 a.m. OK GNU C++11 TESTS 61 577 86835200 2700
45038190 zhangqingqi D Oct. 29, 2018, 8:53 a.m. OK GNU C++14 TESTS 61 655 107622400 2700
45410517 Amorphophallus D Nov. 7, 2018, 11:52 a.m. OK GNU C++14 TESTS 61 670 86835200 2700
50418580 boatinw99 D Feb. 24, 2019, 7:55 a.m. OK GNU C++14 TESTS 61 670 101888000 2700
55677571 Bohun D June 17, 2019, 11:18 a.m. OK GNU C++14 TESTS 61 717 90316800 2700
53609842 vjudge1 D May 1, 2019, 12:26 p.m. OK GNU C++14 TESTS 61 732 96768000 2700
47510557 hfccccccccccccc D Dec. 26, 2018, 6:13 a.m. OK GNU C++14 TESTS 61 732 101683200 2700
69414096 _MGH_ D Jan. 23, 2020, 12:35 p.m. OK GNU C++14 TESTS 61 732 104345600 2700
53836964 withoutpower D May 7, 2019, 4:03 a.m. OK GNU C++14 TESTS 61 733 128614400 2700
41970246 Sdywolf D Aug. 22, 2018, 2:38 p.m. OK GNU C++14 TESTS 61 764 66867200 2700
38385532 zhangzy D May 18, 2018, 1:07 a.m. OK GNU C++14 TESTS 61 764 79257600 2700
45583375 syt1998 D Nov. 12, 2018, 6:28 a.m. OK GNU C++17 TESTS 61 654 82329600 2700
45583588 syt1998 D Nov. 12, 2018, 6:39 a.m. OK GNU C++17 TESTS 61 670 76288000 2700
45583459 syt1998 D Nov. 12, 2018, 6:32 a.m. OK GNU C++17 TESTS 61 670 84377600 2700
68706010 luogu_bot1 D Jan. 13, 2020, 11:19 a.m. OK GNU C++17 TESTS 61 670 86835200 2700
45583687 syt1998 D Nov. 12, 2018, 6:45 a.m. OK GNU C++17 TESTS 61 670 88371200 2700
45583284 syt1998 D Nov. 12, 2018, 6:22 a.m. OK GNU C++17 TESTS 61 685 84377600 2700
69415368 PedyD D Jan. 23, 2020, 12:56 p.m. OK GNU C++17 TESTS 61 685 109875200 2700
45583206 syt1998 D Nov. 12, 2018, 6:18 a.m. OK GNU C++17 TESTS 61 686 81100800 2700
45583315 syt1998 D Nov. 12, 2018, 6:25 a.m. OK GNU C++17 TESTS 61 686 84377600 2700
51945020 vjudge5 D March 28, 2019, 4:24 p.m. OK GNU C++17 TESTS 61 686 95539200 2700
23462319 digiter D Dec. 31, 2016, 4:08 a.m. OK Go TESTS 61 1840 218624000 2700
23462347 digiter D Dec. 31, 2016, 4:10 a.m. OK Go TESTS 61 1871 227532800 2700
23476443 digiter D Dec. 31, 2016, 11:11 p.m. OK Go TESTS 61 2043 208896000 2700
23476513 digiter D Dec. 31, 2016, 11:24 p.m. OK Go TESTS 61 2729 226611200 2700
23414179 digiter D Dec. 30, 2016, 7:07 a.m. OK Go TESTS 61 2901 227123200 2700
24350861 IgorKoval D Feb. 1, 2017, 5:21 p.m. OK Java 8 TESTS 61 1200 275968000 2700
24350932 IgorKoval D Feb. 1, 2017, 5:25 p.m. OK Java 8 TESTS 61 1248 275968000 2700
24351053 IgorKoval D Feb. 1, 2017, 5:30 p.m. OK Java 8 TESTS 61 1263 265318400 2700
22796383 Neumann D Dec. 7, 2016, 7:46 p.m. OK Java 8 TESTS 61 1933 250675200 2700
22787528 uwi D Dec. 7, 2016, 1:41 p.m. OK Java 8 TESTS 61 1981 159334400 2700
22801498 uwi D Dec. 8, 2016, 4:30 a.m. OK Java 8 TESTS 61 2152 159232000 2700
22858340 AtAnyCost D Dec. 10, 2016, 2:44 p.m. OK Java 8 TESTS 61 2948 163328000 2700
23013552 TonySnark D Dec. 15, 2016, 5:19 p.m. OK MS C++ TESTS 61 966 60928000 2700
49933755 vjudge3 D Feb. 15, 2019, 6:12 a.m. OK MS C++ TESTS 61 997 73625600 2700
56370684 vjudge4 D July 1, 2019, 3:25 a.m. OK MS C++ TESTS 61 1029 60825600 2700
55063729 vjudge5 D June 4, 2019, 1:50 a.m. OK MS C++ TESTS 61 1122 81612800 2700
39798322 vjudge4 D June 30, 2018, 12:55 p.m. OK MS C++ TESTS 61 1170 59289600 2700
56369672 vjudge2 D July 1, 2019, 2:38 a.m. OK MS C++ TESTS 61 1170 81715200 2700
53395625 vjudge2 D April 27, 2019, 9:01 a.m. OK MS C++ TESTS 61 1201 255385600 2700
55226328 vjudge5 D June 7, 2019, 1:48 a.m. OK MS C++ TESTS 61 1247 60825600 2700
22911874 AleksanderBalobanov D Dec. 12, 2016, 7:12 p.m. OK MS C++ TESTS 61 1278 119193600 2700
40866549 vjudge2 D July 28, 2018, 3:43 a.m. OK MS C++ TESTS 61 1294 109772800 2700

remove filters

Back to search problems