Technocup 2019 - Elimination Round 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
1031 Technocup 2019 - Elimination Round 2 FINISHED False 7200 191713799 Oct. 21, 2018, 8:10 a.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 3925 ) B Curiosity Has No Limits PROGRAMMING 1500

B'When Masha came to math classes today, she saw two integer sequences of length n - 1 on the blackboard. Let 's denote the elements of the first sequence as a_i ( 0 <= a_i <= 3 ), and the elements of the second sequence as b_i ( 0 <= b_i <= 3 ). Masha became interested if or not there is an integer sequence of length n , which elements we will denote as t_i ( 0 <= t_i <= 3 ), so that for every i ( 1 <= i <= n - 1 ) the following is true: The question appeared to be too difficult for Masha, so now she asked you to check whether such a sequence t_i of length n exists. If it exists, find such a sequence. If there are multiple such sequences, find any of them. The first line contains a single integer n ( 2 <= n <= 10^5 ) -- the length of the sequence t_i . The second line contains n - 1 integers a_1, a_2, ldots, a_{n-1} ( 0 <= a_i <= 3 ) -- the first sequence on the blackboard. The third line contains n - 1 integers b_1, b_2, ldots, b_{n-1} ( 0 <= b_i <= 3 ) -- the second sequence on the blackboard. In the first line print "YES" (without quotes), if there is a sequence t_i that satisfies the conditions from the statements, and "NO" (without quotes), if there is no such sequence. If there is such a sequence, on the second line print n integers t_1, t_2, ldots, t_n ( 0 <= t_i <= 3 ) -- the sequence that satisfies the statements conditions. If there are multiple answers, print any of them. In the first example it 's easy to see that the sequence from output satisfies the given conditions: In the second example there is no such sequence. '...

Tutorials

Codeforces Round #517 and Technocup 2019 Elimination Round 2 Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
44636399 samohovets B Oct. 21, 2018, 9:06 a.m. OK Delphi TESTS 52 61 2252800 1500
44652775 ZhukDima B Oct. 21, 2018, 11:58 a.m. OK FPC TESTS 52 327 1536000 1500
44628957 Nikita2710 B Oct. 21, 2018, 8:27 a.m. OK FPC TESTS 52 327 3584000 1500
44901953 luogu_bot4 B Oct. 26, 2018, 9:31 a.m. OK FPC TESTS 52 327 11264000 1500
45096781 luogu_bot2 B Oct. 30, 2018, 12:11 p.m. OK FPC TESTS 52 327 12083200 1500
44665975 Dark_Furia B Oct. 21, 2018, 5:54 p.m. OK GNU C11 TESTS 52 327 1228800 1500
45422152 Maaddy B Nov. 7, 2018, 6:02 p.m. OK GNU C11 TESTS 52 343 1228800 1500
46280991 vjudge4 B Nov. 27, 2018, 1:21 p.m. OK GNU C11 TESTS 52 343 1228800 1500
45257344 cortan122 B Nov. 3, 2018, 8:53 p.m. OK GNU C11 TESTS 52 358 409600 1500
44775731 vjudge2 B Oct. 24, 2018, 2:16 p.m. OK GNU C++11 TESTS 52 31 1228800 1500
44898759 ouuan B Oct. 26, 2018, 7:59 a.m. OK GNU C++11 TESTS 52 31 4812800 1500
44751736 ReaLNero1 B Oct. 23, 2018, 8:19 p.m. OK GNU C++11 TESTS 52 31 5836800 1500
44674166 Mr-leng B Oct. 22, 2018, 1:34 a.m. OK GNU C++11 TESTS 52 31 14643200 1500
44769441 Riypo_Yian B Oct. 24, 2018, 11:40 a.m. OK GNU C++11 TESTS 52 31 17612800 1500
44682405 vjudge5 B Oct. 22, 2018, 7:22 a.m. OK GNU C++11 TESTS 52 31 23961600 1500
45027835 Nero_Yuzurizaki B Oct. 29, 2018, 12:06 a.m. OK GNU C++11 TESTS 52 31 24064000 1500
44707226 LJFan B Oct. 22, 2018, 5:18 p.m. OK GNU C++11 TESTS 52 46 614400 1500
62574920 xgcjay B Oct. 14, 2019, 3:36 p.m. OK GNU C++11 TESTS 52 46 1228800 1500
63957241 luogu_bot4 B Nov. 1, 2019, 2:46 a.m. OK GNU C++11 TESTS 52 46 1228800 1500
45086489 iliakruchinin B Oct. 30, 2018, 7:40 a.m. OK GNU C++14 TESTS 52 31 42291200 1500
48581160 .tx B Jan. 19, 2019, 4:42 p.m. OK GNU C++14 TESTS 52 46 1228800 1500
44738806 natha B Oct. 23, 2018, 1:49 p.m. OK GNU C++14 TESTS 52 62 819200 1500
55092143 Sturdy B June 4, 2019, 3:05 p.m. OK GNU C++14 TESTS 52 62 1228800 1500
69876159 vjudge3 B Jan. 31, 2020, 4:08 a.m. OK GNU C++14 TESTS 52 62 1228800 1500
65157416 Von. B Nov. 16, 2019, 9:55 a.m. OK GNU C++14 TESTS 52 62 1228800 1500
61706593 chandrachud200 B Oct. 2, 2019, 10:17 a.m. OK GNU C++14 TESTS 52 62 1228800 1500
57861648 begv B July 27, 2019, 6:09 p.m. OK GNU C++14 TESTS 52 62 1228800 1500
52601104 vjudge2 B April 11, 2019, 11:57 a.m. OK GNU C++14 TESTS 52 62 1228800 1500
49847919 AMnu B Feb. 13, 2019, 12:03 a.m. OK GNU C++14 TESTS 52 62 1228800 1500
63957242 mzg1806 B Nov. 1, 2019, 2:46 a.m. OK GNU C++17 TESTS 52 46 1228800 1500
45897390 maxuh14 B Nov. 18, 2018, 12:29 a.m. OK GNU C++17 TESTS 52 46 1638400 1500
44666613 Excogitatoris B Oct. 21, 2018, 6:17 p.m. OK GNU C++17 TESTS 52 46 4710400 1500
44680471 Anguei B Oct. 22, 2018, 6 a.m. OK GNU C++17 TESTS 52 46 5017600 1500
52953057 Jenius B April 18, 2019, 12:41 p.m. OK GNU C++17 TESTS 52 61 1228800 1500
46247223 yikai123 B Nov. 26, 2018, 12:07 p.m. OK GNU C++17 TESTS 52 61 1228800 1500
44634280 -BinaryTreeSort- B Oct. 21, 2018, 8:55 a.m. OK GNU C++17 TESTS 52 61 1228800 1500
45897368 maxuh14 B Nov. 18, 2018, 12:28 a.m. OK GNU C++17 TESTS 52 61 1536000 1500
44626564 Dalgerok B Oct. 21, 2018, 8:19 a.m. OK GNU C++17 TESTS 52 61 4198400 1500
44679874 oso_pardo3 B Oct. 22, 2018, 5:29 a.m. OK GNU C++17 TESTS 52 62 1024000 1500
45667898 davidguandev B Nov. 13, 2018, 8:46 a.m. OK Go TESTS 52 46 716800 1500
64674166 potatmen B Nov. 11, 2019, 7:20 a.m. OK Java 11 TESTS 52 218 0 1500
44631541 amir7777 B Oct. 21, 2018, 8:40 a.m. OK Java 8 TESTS 52 124 0 1500
44649863 pereb4ik B Oct. 21, 2018, 11:14 a.m. OK Java 8 TESTS 52 139 0 1500
55388437 jebaited B June 10, 2019, 8:36 a.m. OK Java 8 TESTS 52 140 0 1500
44742221 Rustemhak B Oct. 23, 2018, 3:10 p.m. OK Java 8 TESTS 52 140 0 1500
44713977 4mda4mda B Oct. 22, 2018, 8:21 p.m. OK Java 8 TESTS 52 155 0 1500
63404790 mikhaylov_boris B Oct. 25, 2019, 7:50 p.m. OK Java 8 TESTS 52 155 0 1500
50289128 mikkk B Feb. 21, 2019, 4:31 p.m. OK Java 8 TESTS 52 155 0 1500
44881404 KulikAlex B Oct. 25, 2018, 7:18 p.m. OK Java 8 TESTS 52 155 0 1500
44645306 Snapman B Oct. 21, 2018, 9:56 a.m. OK Java 8 TESTS 52 155 0 1500
44645033 Nutella3000 B Oct. 21, 2018, 9:55 a.m. OK Java 8 TESTS 52 155 0 1500
45109058 dimoff66 B Oct. 30, 2018, 5:33 p.m. OK JavaScript TESTS 52 109 9216000 1500
56548374 og.kostya B July 5, 2019, 8:37 a.m. OK Mono C# TESTS 52 78 6041600 1500
45413157 Mem B Nov. 7, 2018, 12:57 p.m. OK Mono C# TESTS 52 109 11366400 1500
44634226 Feodor123 B Oct. 21, 2018, 8:54 a.m. OK Mono C# TESTS 52 109 12083200 1500
44662896 NEvOl B Oct. 21, 2018, 4:11 p.m. OK Mono C# TESTS 52 420 15872000 1500
44788942 Merlin B Oct. 24, 2018, 5 p.m. OK MS C++ TESTS 52 46 1228800 1500
59596565 vjudge2 B Aug. 28, 2019, 2:17 a.m. OK MS C++ TESTS 52 46 3584000 1500
65024260 vjudge3 B Nov. 15, 2019, 6:51 a.m. OK MS C++ TESTS 52 62 1228800 1500
44734581 vjudge5 B Oct. 23, 2018, 12:17 p.m. OK MS C++ TESTS 52 62 1228800 1500
45379974 scorpiowf B Nov. 6, 2018, 2:12 p.m. OK MS C++ TESTS 52 62 2764800 1500
45590258 Houbunsha B Nov. 12, 2018, 11:58 a.m. OK MS C++ TESTS 52 77 1228800 1500
44662198 Ivan11 B Oct. 21, 2018, 3:48 p.m. OK MS C++ TESTS 52 78 1228800 1500
60583466 PavelBr B Sept. 14, 2019, 7:38 p.m. OK MS C++ TESTS 52 124 307200 1500
46115435 vjudge4 B Nov. 23, 2018, 1:44 p.m. OK MS C++ TESTS 52 124 1228800 1500
46110144 vjudge1 B Nov. 23, 2018, 11:47 a.m. OK MS C++ TESTS 52 124 2764800 1500
44670366 InyaLime B Oct. 21, 2018, 8:47 p.m. OK Ocaml TESTS 52 187 22323200 1500
44651204 VadKsen B Oct. 21, 2018, 11:31 a.m. OK PascalABC.NET TESTS 52 374 4096000 1500
44928728 Ms_butovchenko B Oct. 26, 2018, 10:01 p.m. OK PascalABC.NET TESTS 52 654 14848000 1500
45117822 aleksey2101 B Oct. 30, 2018, 11:46 p.m. OK PascalABC.NET TESTS 52 655 4096000 1500
44985847 NYARENARD B Oct. 28, 2018, 10:19 a.m. OK PascalABC.NET TESTS 52 655 14848000 1500
44928792 Ms_butovchenko B Oct. 26, 2018, 10:05 p.m. OK PascalABC.NET TESTS 52 670 4096000 1500
44929356 Ms_butovchenko B Oct. 26, 2018, 10:49 p.m. OK PascalABC.NET TESTS 52 670 4096000 1500
44929258 Ms_butovchenko B Oct. 26, 2018, 10:41 p.m. OK PascalABC.NET TESTS 52 670 4096000 1500
44929568 Ms_butovchenko B Oct. 26, 2018, 11:08 p.m. OK PascalABC.NET TESTS 52 670 5324800 1500
44663886 n1k33219 B Oct. 21, 2018, 4:45 p.m. OK PascalABC.NET TESTS 52 685 3174400 1500
44629505 ilya105 B Oct. 21, 2018, 8:29 a.m. OK PascalABC.NET TESTS 52 686 4096000 1500
45155797 wangkan2001 B Nov. 1, 2018, 1:24 a.m. OK PyPy 2 TESTS 52 171 7680000 1500
44639150 max_hha B Oct. 21, 2018, 9:21 a.m. OK PyPy 3 TESTS 52 218 11161600 1500
44641851 Bykov_David B Oct. 21, 2018, 9:37 a.m. OK PyPy 3 TESTS 52 249 9318400 1500
45113994 Patwari26 B Oct. 30, 2018, 8:09 p.m. OK PyPy 3 TESTS 52 249 11264000 1500
44638923 boytsova B Oct. 21, 2018, 9:20 a.m. OK PyPy 3 TESTS 52 249 11366400 1500
44637096 malo.detz B Oct. 21, 2018, 9:10 a.m. OK PyPy 3 TESTS 52 249 11366400 1500
44645890 karpik B Oct. 21, 2018, 9:59 a.m. OK PyPy 3 TESTS 52 264 9113600 1500
46357633 gaoadt B Nov. 29, 2018, 9:15 a.m. OK PyPy 3 TESTS 52 311 10444800 1500
44646488 Mr_ChAI B Oct. 21, 2018, 10:02 a.m. OK Python 3 TESTS 52 296 6144000 1500
44630367 rzhikharevich B Oct. 21, 2018, 8:34 a.m. OK Python 3 TESTS 52 296 6144000 1500
44691315 r57shell B Oct. 22, 2018, 12:10 p.m. OK Python 3 TESTS 52 358 2457600 1500
44662778 Ser__007 B Oct. 21, 2018, 4:07 p.m. OK Python 3 TESTS 52 358 16281600 1500
44662808 LadyPython B Oct. 21, 2018, 4:08 p.m. OK Python 3 TESTS 52 373 2560000 1500
44701761 dzham183 B Oct. 22, 2018, 3:05 p.m. OK Python 3 TESTS 52 389 2560000 1500
44661285 nexus.chebykin B Oct. 21, 2018, 3:20 p.m. OK Python 3 TESTS 52 405 2662400 1500
44632009 dudko_mv B Oct. 21, 2018, 8:43 a.m. OK Python 3 TESTS 52 451 2560000 1500
44641042 Lobanov_Dmitry B Oct. 21, 2018, 9:32 a.m. OK Python 3 TESTS 52 452 2867200 1500
44651114 SddKrab B Oct. 21, 2018, 11:30 a.m. OK Python 3 TESTS 52 467 2867200 1500
44653144 Dx18 B Oct. 21, 2018, 12:05 p.m. OK Rust TESTS 52 31 716800 1500

remove filters

Back to search problems