Educational Codeforces Round 46 (Rated for 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
1000 Educational Codeforces Round 46 (Rated for Div. 2) FINISHED False 7200 201713099 June 27, 2018, 2:35 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 3923 ) F One Occurrence PROGRAMMING data structures divide and conquer 2400

B'You are given an array a consisting of n integers, and q queries to it. i -th query is denoted by two integers l_i and r_i . For each query, you have to find any integer that occurs exactly once in the subarray of a from index l_i to index r_i (a subarray is a contiguous subsegment of an array). For example, if a = [1, 1, 2, 3, 2, 4] , then for query (l_i = 2, r_i = 6) the subarray we are interested in is [1, 2, 3, 2, 4] , and possible answers are 1 , 3 and 4 ; for query (l_i = 1, r_i = 2) the subarray we are interested in is [1, 1] , and there is no such element that occurs exactly once. Can you answer all of the queries? The first line contains one integer n ( 1 <= n <= 5 cdot 10^5 ). The second line contains n integers a_1, a_2, ... , a_n ( 1 <= a_i <= 5 cdot 10^5 ). The third line contains one integer q ( 1 <= q <= 5 cdot 10^5 ). Then q lines follow, i -th line containing two integers l_i and r_i representing i -th query ( 1 <= l_i <= r_i <= n ). Answer the queries as follows: If there is no integer such that it occurs in the subarray from index l_i to index r_i exactly once, print 0 . Otherwise print any such integer. '...

Tutorials

60288

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
39720408 EricHuang2003 F June 27, 2018, 4:27 p.m. OK GNU C++ TESTS 70 2074 22425600 2400
39713335 wzp233 F June 27, 2018, 3:29 p.m. OK GNU C++ TESTS 70 2371 163328000 2400
39720231 EricHuang2003 F June 27, 2018, 4:26 p.m. OK GNU C++ TESTS 70 2417 22425600 2400
39707695 Claris F June 27, 2018, 2:54 p.m. OK GNU C++11 TESTS 70 717 32563200 2400
39720559 SmokeOut F June 27, 2018, 4:29 p.m. OK GNU C++11 TESTS 70 811 44134400 2400
39716309 darked F June 27, 2018, 3:53 p.m. OK GNU C++11 TESTS 70 826 47001600 2400
39721372 tfg F June 27, 2018, 4:34 p.m. OK GNU C++11 TESTS 70 966 134348800 2400
39718727 iZard F June 27, 2018, 4:14 p.m. OK GNU C++11 TESTS 70 998 65843200 2400
39717151 Magolor F June 27, 2018, 4 p.m. OK GNU C++11 TESTS 70 1075 51814400 2400
39718721 SnapOutOfIt F June 27, 2018, 4:14 p.m. OK GNU C++11 TESTS 70 1575 88576000 2400
39720989 tfg F June 27, 2018, 4:32 p.m. OK GNU C++11 TESTS 70 2620 134451200 2400
39719310 Lius F June 27, 2018, 4:19 p.m. OK GNU C++11 TESTS 70 2948 15974400 2400
39718313 natsugiri F June 27, 2018, 4:11 p.m. OK GNU C++14 TESTS 70 577 16281600 2400
39718180 taow F June 27, 2018, 4:09 p.m. OK GNU C++14 TESTS 70 873 36249600 2400
39715859 XZA F June 27, 2018, 3:49 p.m. OK GNU C++14 TESTS 70 889 43315200 2400
39710044 step_by_step F June 27, 2018, 3:08 p.m. OK GNU C++14 TESTS 70 951 34304000 2400
39710032 radoslav11 F June 27, 2018, 3:07 p.m. OK GNU C++14 TESTS 70 966 71987200 2400
39713460 Farhod_Farmon F June 27, 2018, 3:30 p.m. OK GNU C++14 TESTS 70 967 41881600 2400
39713076 _Ash__ F June 27, 2018, 3:28 p.m. OK GNU C++14 TESTS 70 982 34918400 2400
39721211 Powerslave F June 27, 2018, 4:33 p.m. OK GNU C++14 TESTS 70 982 37376000 2400
39719961 Dalgerok F June 27, 2018, 4:24 p.m. OK GNU C++14 TESTS 70 998 37068800 2400
39712763 win11905 F June 27, 2018, 3:25 p.m. OK GNU C++14 TESTS 70 1044 32358400 2400

remove filters

Back to search problems