Codeforces Round 338 (Div. 2)

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
615 Codeforces Round 338 (Div. 2) FINISHED False 7200 285350104 Jan. 8, 2016, 2:05 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 2352 ) C Running Track PROGRAMMING dp greedy strings trees 1900

B'A boy named Ayrat lives on planet AMI-1511. Each inhabitant of this planet has a talent. Specifically, Ayrat loves running, moreover, just running is not enough for him. He is dreaming of making running a real art. First, he wants to construct the running track with coating t. On planet AMI-1511 the coating of the track is the sequence of colored blocks, where each block is denoted as the small English letter. Therefore, every coating can be treated as a string. Unfortunately, blocks aren 't freely sold to non-business customers, but Ayrat found an infinite number of coatings s. Also, he has scissors and glue. Ayrat is going to buy some coatings s, then cut out from each of them exactly one continuous piece (substring) and glue it to the end of his track coating. Moreover, he may choose to flip this block before glueing it. Ayrat want 's to know the minimum number of coating s he needs to buy in order to get the coating t for his running track. Of course, he also want 's to know some way to achieve the answer. First line of the input contains the string s -- the coating that is present in the shop. Second line contains the string t -- the coating Ayrat wants to obtain. Both strings are non-empty, consist of only small English letters and their length doesn 't exceed 2100. The first line should contain the minimum needed number of coatings n or -1 if it 's impossible to create the desired coating. If the answer is not -1, then the following n lines should contain two integers xi and yi -- numbers of ending blocks in the corresponding piece. If xi xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89yi then this piece is used in the regular order, and if xi xe2 x80 x89> xe2 x80 x89yi piece is used in the reversed order. Print the pieces in the order they should be glued to get the string t. In the first sample string "cbaabc" = "cba" + "abc". In the second sample: "ayrat" = "a" + "yr" + "at".'...

Tutorials

Codeforces Round #338 (Div. 2) editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
15282847 ruban C Jan. 10, 2016, 5:47 p.m. OK Delphi TESTS 67 46 17612800 1900
16827641 Andrey15253545 C March 19, 2016, 9:08 p.m. OK Delphi TESTS 67 62 2764800 1900
17016631 favstovol C March 29, 2016, 9:08 a.m. OK Delphi TESTS 67 109 2560000 1900
15270717 irevt C Jan. 9, 2016, 2:22 p.m. OK FPC TESTS 67 31 1126400 1900
15253765 igdor99 C Jan. 8, 2016, 4 p.m. OK FPC TESTS 67 31 6246400 1900
15254448 khongbietdatten22107 C Jan. 8, 2016, 4:03 p.m. OK FPC TESTS 67 46 512000 1900
15763276 ez_zkj C Feb. 3, 2016, 6:42 a.m. OK FPC TESTS 67 62 50483200 1900
15727857 XuDuSh C Feb. 1, 2016, 9:03 a.m. OK FPC TESTS 67 78 307200 1900
15249161 Kleaschev_Maksim C Jan. 8, 2016, 3:24 p.m. OK FPC TESTS 67 78 512000 1900
17591157 Gray_58 C April 30, 2016, 7:40 a.m. OK FPC TESTS 67 78 52224000 1900
15254962 DenXman111 C Jan. 8, 2016, 4:35 p.m. OK FPC TESTS 67 93 170803200 1900
20296332 Quan1999nt C Aug. 31, 2016, 7:48 a.m. OK FPC TESTS 67 109 614400 1900
15248308 s34vv1nd C Jan. 8, 2016, 3:16 p.m. OK FPC TESTS 67 139 614400 1900
27723541 vjudge5 C June 11, 2017, 3:45 p.m. OK GNU C++ TESTS 67 15 0 1900
27267250 dengdeng123 C May 21, 2017, 12:46 p.m. OK GNU C++ TESTS 67 15 0 1900
22694124 vjudge4 C Dec. 4, 2016, 11:03 a.m. OK GNU C++ TESTS 67 15 0 1900
20550343 shubhamgarg18 shubhiks1032 siddharth1998 C Sept. 12, 2016, 1:53 p.m. OK GNU C++ TESTS 67 15 0 1900
16319542 TCgogogo C Feb. 25, 2016, 3:51 a.m. OK GNU C++ TESTS 67 15 0 1900
16296279 kbnzlevy C Feb. 23, 2016, 4:46 p.m. OK GNU C++ TESTS 67 15 0 1900
15973958 vjudge1 C Feb. 12, 2016, 4:05 p.m. OK GNU C++ TESTS 67 15 0 1900
15688765 grated C Jan. 31, 2016, 3:50 a.m. OK GNU C++ TESTS 67 15 0 1900
15595633 lgr745 C Jan. 26, 2016, 2:49 p.m. OK GNU C++ TESTS 67 15 0 1900
15509030 DTDT C Jan. 23, 2016, 6:35 a.m. OK GNU C++ TESTS 67 15 0 1900
56993038 rainboy C July 13, 2019, 7:35 p.m. OK GNU C11 TESTS 67 61 35430400 1900
15983697 1917 C Feb. 13, 2016, 8:13 a.m. OK GNU C++11 TESTS 67 15 0 1900
19217067 JJboom C July 18, 2016, 5:03 p.m. OK GNU C++11 TESTS 67 15 0 1900
15956501 Flash-boy C Feb. 11, 2016, 1:18 p.m. OK GNU C++11 TESTS 67 15 0 1900
15951602 zy1997 C Feb. 11, 2016, 6:58 a.m. OK GNU C++11 TESTS 67 15 0 1900
15611613 Z_silence C Jan. 27, 2016, 12:46 p.m. OK GNU C++11 TESTS 67 15 0 1900
15606107 enstein_jun C Jan. 27, 2016, 6:22 a.m. OK GNU C++11 TESTS 67 15 0 1900
15509809 delacour01 C Jan. 23, 2016, 7:21 a.m. OK GNU C++11 TESTS 67 15 0 1900
15496058 I_love_code C Jan. 22, 2016, 9:52 a.m. OK GNU C++11 TESTS 67 15 0 1900
15452290 vjudge3 C Jan. 20, 2016, 11:33 a.m. OK GNU C++11 TESTS 67 15 0 1900
15416682 lkdmhy C Jan. 17, 2016, 4:18 p.m. OK GNU C++11 TESTS 67 15 0 1900
20614939 daydayz C Sept. 14, 2016, 1:12 p.m. OK GNU C++14 TESTS 67 15 0 1900
29704165 21August C Aug. 23, 2017, 10:25 a.m. OK GNU C++14 TESTS 67 15 307200 1900
22804601 abdullah009 C Dec. 8, 2016, 8:12 a.m. OK GNU C++14 TESTS 67 15 1945600 1900
34942694 2390_ C Feb. 5, 2018, 11:51 a.m. OK GNU C++14 TESTS 67 15 1945600 1900
22804661 abdullah009 C Dec. 8, 2016, 8:16 a.m. OK GNU C++14 TESTS 67 15 1945600 1900
26338202 shivang_bansal C April 13, 2017, 1:28 p.m. OK GNU C++14 TESTS 67 15 2048000 1900
33573126 gaporf C Dec. 23, 2017, 5:03 p.m. OK GNU C++14 TESTS 67 15 2969600 1900
25780193 giraffeh C March 24, 2017, 6:05 p.m. OK GNU C++14 TESTS 67 15 4608000 1900
55600650 angusLIN C June 15, 2019, 6:06 p.m. OK GNU C++14 TESTS 67 30 0 1900
59420004 repeat_ C Aug. 24, 2019, 8:25 p.m. OK GNU C++14 TESTS 67 30 307200 1900
57008250 vjudge4 C July 14, 2019, 7:53 a.m. OK GNU C++17 TESTS 67 30 2048000 1900
57017294 vjudge2 C July 14, 2019, 12:14 p.m. OK GNU C++17 TESTS 67 31 0 1900
57016864 vjudge5 C July 14, 2019, 12:02 p.m. OK GNU C++17 TESTS 67 31 0 1900
51364621 maozaozao C March 16, 2019, 8:58 a.m. OK GNU C++17 TESTS 67 31 0 1900
50270602 vjudge2 C Feb. 21, 2019, 7:03 a.m. OK GNU C++17 TESTS 67 31 0 1900
57017327 vjudge4 C July 14, 2019, 12:15 p.m. OK GNU C++17 TESTS 67 31 102400 1900
54916521 grtcoder C June 1, 2019, 2:08 p.m. OK GNU C++17 TESTS 67 31 102400 1900
46531599 vjudge5 C Dec. 3, 2018, 5:58 a.m. OK GNU C++17 TESTS 67 31 102400 1900
45392127 yue07 C Nov. 6, 2018, 10:44 p.m. OK GNU C++17 TESTS 67 31 102400 1900
43021419 muzzle C Sept. 18, 2018, 5:19 a.m. OK GNU C++17 TESTS 67 31 102400 1900
43663125 starius C Oct. 1, 2018, 8:14 p.m. OK Go TESTS 67 93 40960000 1900
15276613 uronce C Jan. 10, 2016, 6:14 a.m. OK Go TESTS 67 592 48742400 1900
15286513 Code.coding C Jan. 11, 2016, 10:38 a.m. OK Java 7 TESTS 67 124 0 1900
15286503 akdent C Jan. 11, 2016, 10:38 a.m. OK Java 7 TESTS 67 124 0 1900
15283908 AL_DEEB C Jan. 10, 2016, 8:15 p.m. OK Java 7 TESTS 67 139 0 1900
15379201 chauncyc C Jan. 14, 2016, 11:28 p.m. OK Java 7 TESTS 67 155 0 1900
15263785 DukeOfYork C Jan. 9, 2016, 5:01 a.m. OK Java 7 TESTS 67 155 0 1900
15249359 rwali C Jan. 8, 2016, 3:25 p.m. OK Java 7 TESTS 67 155 0 1900
15905530 megaspazz C Feb. 9, 2016, 5:05 a.m. OK Java 7 TESTS 67 170 53043200 1900
15252814 nandarustam C Jan. 8, 2016, 3:53 p.m. OK Java 7 TESTS 67 171 0 1900
15284757 aste C Jan. 10, 2016, 11:28 p.m. OK Java 7 TESTS 67 171 204800 1900
15276625 riversouther C Jan. 10, 2016, 6:15 a.m. OK Java 7 TESTS 67 186 0 1900
16536168 alexrcoleman C March 5, 2016, 2:45 p.m. OK Java 8 TESTS 67 124 0 1900
15309613 meijun C Jan. 12, 2016, 8:38 a.m. OK Java 8 TESTS 67 124 0 1900
15303475 vin_74 C Jan. 11, 2016, 6:55 p.m. OK Java 8 TESTS 67 124 0 1900
15261106 ilya-s C Jan. 8, 2016, 9:41 p.m. OK Java 8 TESTS 67 124 0 1900
15253202 akshay_miterani C Jan. 8, 2016, 3:56 p.m. OK Java 8 TESTS 67 124 0 1900
15305023 sruzic C Jan. 11, 2016, 10:04 p.m. OK Java 8 TESTS 67 140 0 1900
15261044 baobab C Jan. 8, 2016, 9:33 p.m. OK Java 8 TESTS 67 140 0 1900
15261014 uwi C Jan. 8, 2016, 9:27 p.m. OK Java 8 TESTS 67 140 0 1900
15248273 2oo7 C Jan. 8, 2016, 3:16 p.m. OK Java 8 TESTS 67 140 0 1900
26949750 quinamatics C May 8, 2017, 3:42 a.m. OK Java 8 TESTS 67 155 0 1900
15269336 DigitalArtistKz C Jan. 9, 2016, 12:21 p.m. OK Mono C# TESTS 67 77 2764800 1900
15258769 Beresta C Jan. 8, 2016, 6:22 p.m. OK MS C# TESTS 67 62 2764800 1900
15256601 leonidvasilyev C Jan. 8, 2016, 4:57 p.m. OK MS C# TESTS 67 77 204800 1900
15264632 gnihton C Jan. 9, 2016, 6:18 a.m. OK MS C# TESTS 67 77 2867200 1900
15270193 og.kostya C Jan. 9, 2016, 1:36 p.m. OK MS C# TESTS 67 93 3788800 1900
15257824 Beresta C Jan. 8, 2016, 5:35 p.m. OK MS C# TESTS 67 93 5222400 1900
15272948 Dreamer111 C Jan. 9, 2016, 6:07 p.m. OK MS C# TESTS 67 93 5324800 1900
15272956 Dreamer111 C Jan. 9, 2016, 6:07 p.m. OK MS C# TESTS 67 93 5427200 1900
15285804 AnatolyTolstobrov C Jan. 11, 2016, 9:12 a.m. OK MS C# TESTS 67 109 4812800 1900
15311148 azukun C Jan. 12, 2016, 10:52 a.m. OK MS C# TESTS 67 124 5734400 1900
15263763 camypaper C Jan. 9, 2016, 4:58 a.m. OK MS C# TESTS 67 140 44134400 1900
15258448 dilshodp C Jan. 8, 2016, 6:05 p.m. OK MS C++ TESTS 67 15 0 1900
15491503 vjudge3 C Jan. 22, 2016, 5:58 a.m. OK MS C++ TESTS 67 15 0 1900
15250200 htzfun C Jan. 8, 2016, 3:32 p.m. OK MS C++ TESTS 67 15 102400 1900
15647706 Cherser C Jan. 29, 2016, 2:58 p.m. OK MS C++ TESTS 67 15 102400 1900
15262889 nevergiveup C Jan. 9, 2016, 3:05 a.m. OK MS C++ TESTS 67 15 102400 1900
15261181 NVAL C Jan. 8, 2016, 9:53 p.m. OK MS C++ TESTS 67 15 819200 1900
15319335 Milanin C Jan. 12, 2016, 4:25 p.m. OK MS C++ TESTS 67 30 0 1900
15250074 FaeeLoL1 C Jan. 8, 2016, 3:31 p.m. OK MS C++ TESTS 67 30 0 1900
15247800 Maxim_Seredkin C Jan. 8, 2016, 3:12 p.m. OK MS C++ TESTS 67 30 102400 1900
31825431 vjudge5 C Oct. 28, 2017, 5:44 a.m. OK MS C++ TESTS 67 30 204800 1900
15438469 Kasia C Jan. 19, 2016, 10:30 a.m. OK Ocaml TESTS 67 264 2867200 1900
15267663 mayakin C Jan. 9, 2016, 10:22 a.m. OK PHP TESTS 67 62 512000 1900
15287773 biomat C Jan. 11, 2016, 12:56 p.m. OK PyPy 2 TESTS 67 124 2252800 1900
15969609 A.Arslan2016 C Feb. 12, 2016, 11:11 a.m. OK PyPy 2 TESTS 67 155 2252800 1900
15331419 Fekete C Jan. 13, 2016, 1:31 p.m. OK PyPy 2 TESTS 67 171 2252800 1900
15302619 my-zhang C Jan. 11, 2016, 5:54 p.m. OK PyPy 2 TESTS 67 217 4198400 1900
35895738 ______u______ C March 3, 2018, 4:52 p.m. OK PyPy 3 TESTS 67 140 22016000 1900
35887633 ______h______ C March 3, 2018, 2:07 p.m. OK PyPy 3 TESTS 67 140 22016000 1900
35886324 ______i______ C March 3, 2018, 1:44 p.m. OK PyPy 3 TESTS 67 140 22016000 1900
35884398 ______M______ C March 3, 2018, 1:10 p.m. OK PyPy 3 TESTS 67 140 22016000 1900
32620685 yugle7 C Nov. 24, 2017, 12:30 p.m. OK PyPy 3 TESTS 67 171 25804800 1900
15584790 koderXXX C Jan. 26, 2016, 1:57 a.m. OK PyPy 3 TESTS 67 187 3993600 1900
32620146 yugle7 C Nov. 24, 2017, 12:13 p.m. OK PyPy 3 TESTS 67 187 27443200 1900
15304810 Seyfert C Jan. 11, 2016, 9:30 p.m. OK Python 2 TESTS 67 77 102400 1900
15267360 ashwani16 C Jan. 9, 2016, 9:58 a.m. OK Python 2 TESTS 67 77 102400 1900
15257220 absolutezero C Jan. 8, 2016, 5:14 p.m. OK Python 2 TESTS 67 77 102400 1900
15248116 mathturbator C Jan. 8, 2016, 3:15 p.m. OK Python 2 TESTS 67 77 204800 1900
18497562 leslie071564 C June 15, 2016, 12:52 p.m. OK Python 2 TESTS 67 77 4812800 1900
15252988 belowthebelt C Jan. 8, 2016, 3:54 p.m. OK Python 2 TESTS 67 93 102400 1900
47840776 kansagara C Jan. 2, 2019, 11:48 a.m. OK Python 2 TESTS 67 202 204800 1900
15251331 redviper C Jan. 8, 2016, 3:42 p.m. OK Python 3 TESTS 67 78 614400 1900
26466048 kastuss C April 18, 2017, 12:27 a.m. OK Python 3 TESTS 67 109 5734400 1900
15435774 baturayk C Jan. 19, 2016, 6:15 a.m. OK Python 3 TESTS 67 124 409600 1900
15278895 surokpro C Jan. 10, 2016, 10:34 a.m. OK Python 3 TESTS 67 124 614400 1900
68854121 tushartyagi8750 C Jan. 15, 2020, 10:03 a.m. OK Python 3 TESTS 67 124 1126400 1900
15253429 Artuursp C Jan. 8, 2016, 3:57 p.m. OK Python 3 TESTS 67 155 512000 1900
42136223 Mk_Python_v1 C Aug. 27, 2018, 12:16 a.m. OK Python 3 TESTS 67 171 716800 1900
17286072 wujuihsuan2016 C April 12, 2016, 6 a.m. OK Python 3 TESTS 67 467 921600 1900
15271464 honeysleep C Jan. 9, 2016, 3:33 p.m. OK Scala TESTS 67 608 512000 1900
18095138 dr.ikros C May 26, 2016, 12:24 a.m. OK Scala TESTS 67 733 40755200 1900

remove filters

Back to search problems