Codeforces Round 260 (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
455 Codeforces Round 260 (Div. 1) FINISHED False 7200 324311399 Aug. 8, 2014, 3:30 p.m.

Problems

Solved$
Index
Name
Type
Tags
Community Tag
Rating
( 3029 ) D Serega and Fun PROGRAMMING data structures 2600

B"Serega loves fun. However, everyone has fun in the unique manner. Serega has fun by solving query problems. One day Fedor came up with such a problem. You are given an array a consisting of n positive integers and queries to it. The queries can be of two types: Fedor hurried to see Serega enjoy the problem and Serega solved it really quickly. Let's see, can you solve it? The first line contains integer n (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89105) -- the number of elements of the array. The second line contains n integers a[1], xe2 x80 x89a[2], xe2 x80 x89..., xe2 x80 x89a[n] (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89a[i] xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n). The third line contains a single integer q (1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89q xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89105) -- the number of queries. The next q lines contain the queries. As you need to respond to the queries online, the queries will be encoded. A query of the first type will be given in format: 1 l'i r'i. A query of the second type will be given in format: 2 l'i r'i k'i. All the number in input are integer. They satisfy the constraints: 1 xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89l'i, xe2 x80 x89r'i, xe2 x80 x89k'i xe2 x80 x89 xe2 x89 xa4 xe2 x80 x89n. To decode the queries from the data given in input, you need to perform the following transformations: Where lastans is the last reply to the query of the 2-nd type (initially, lastans xe2 x80 x89= xe2 x80 x890). If after transformation li is greater than ri, you must swap these values. For each query of the 2-nd type print the answer on a single line."...

Tutorials

Codeforces Round #260 — Editorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
35573245 AutumnKite D Feb. 22, 2018, 12:47 p.m. OK GNU C++ TESTS 69 202 125952000 2600
38252751 Zhang_RQ D May 15, 2018, 1:01 a.m. OK GNU C++ TESTS 69 234 7987200 2600
36292532 ElDestructor D March 15, 2018, 7:29 a.m. OK GNU C++ TESTS 69 467 13414400 2600
42305679 Scut82 D Aug. 31, 2018, 11:04 a.m. OK GNU C++ TESTS 69 546 258150400 2600
40768083 yts1999 D July 26, 2018, 7:21 a.m. OK GNU C++ TESTS 69 732 265830400 2600
42079871 Scut82 D Aug. 25, 2018, 7:42 a.m. OK GNU C++ TESTS 69 748 130764800 2600
38948097 vjudge5 D June 4, 2018, 2:48 p.m. OK GNU C++ TESTS 69 889 135065600 2600
35982326 vjudge3 D March 6, 2018, 5:55 a.m. OK GNU C++ TESTS 69 904 204288000 2600
38948011 vjudge5 D June 4, 2018, 2:44 p.m. OK GNU C++ TESTS 69 919 135065600 2600
36413876 vjudge2 D March 19, 2018, 2:50 p.m. OK GNU C++ TESTS 69 997 136806400 2600
40988150 ReaLNero1 D July 30, 2018, 9:46 p.m. OK GNU C++11 TESTS 69 186 5222400 2600
44729548 cly_none D Oct. 23, 2018, 9:46 a.m. OK GNU C++11 TESTS 69 264 10035200 2600
35192419 Mackerel_Pike D Feb. 13, 2018, 7:20 a.m. OK GNU C++11 TESTS 69 342 82841600 2600
34649398 choutii D Jan. 29, 2018, 4:18 a.m. OK GNU C++11 TESTS 69 358 47513600 2600
57456862 2016wudi D July 21, 2019, 11:59 a.m. OK GNU C++11 TESTS 69 373 141926400 2600
49905693 luogu_bot3 D Feb. 14, 2019, 11:51 a.m. OK GNU C++11 TESTS 69 373 163123200 2600
49905710 vjudge4 D Feb. 14, 2019, 11:51 a.m. OK GNU C++11 TESTS 69 374 163123200 2600
38722502 naive_wcx D May 29, 2018, 3:21 p.m. OK GNU C++11 TESTS 69 436 44646400 2600
47958659 vjudge5 D Jan. 5, 2019, 8:01 a.m. OK GNU C++11 TESTS 69 451 40960000 2600
43293785 sunzhihong D Sept. 23, 2018, 12:15 p.m. OK GNU C++11 TESTS 69 468 8908800 2600
43081921 vjudge2 D Sept. 19, 2018, 2:14 p.m. OK GNU C++14 TESTS 69 327 3993600 2600
35215175 ShakuganSky D Feb. 13, 2018, 6:22 p.m. OK GNU C++14 TESTS 69 358 82329600 2600
33246853 Bassel D Dec. 14, 2017, 5:20 p.m. OK GNU C++14 TESTS 69 358 134963200 2600
33246999 Bassel D Dec. 14, 2017, 5:26 p.m. OK GNU C++14 TESTS 69 374 42393600 2600
44756104 CrazyDave D Oct. 24, 2018, 1:22 a.m. OK GNU C++14 TESTS 69 421 83660800 2600
44733145 lllllllllllllllllllllll D Oct. 23, 2018, 11:37 a.m. OK GNU C++14 TESTS 69 436 203878400 2600
44767699 CrazyDave D Oct. 24, 2018, 10:52 a.m. OK GNU C++14 TESTS 69 451 83660800 2600
44733053 lllllllllllllllllllllll D Oct. 23, 2018, 11:34 a.m. OK GNU C++14 TESTS 69 482 203878400 2600
34829072 lhclqslove D Feb. 2, 2018, 6:42 a.m. OK GNU C++14 TESTS 69 529 165171200 2600
42127145 kataki D Aug. 26, 2018, 3:59 p.m. OK GNU C++14 TESTS 69 545 130150400 2600
44444051 zjp_shadow D Oct. 17, 2018, 1:14 p.m. OK GNU C++17 TESTS 69 327 4505600 2600
68365861 keko37 D Jan. 7, 2020, 3:56 p.m. OK GNU C++17 TESTS 69 358 5632000 2600
58123455 llbra9z D Aug. 1, 2019, 11:43 a.m. OK GNU C++17 TESTS 69 389 6041600 2600
58122597 llbra9z D Aug. 1, 2019, 11:25 a.m. OK GNU C++17 TESTS 69 389 6041600 2600
68460367 RedStone D Jan. 9, 2020, 5:51 p.m. OK GNU C++17 TESTS 69 405 165990400 2600
66278506 Happy_Stove D Dec. 4, 2019, 4:10 p.m. OK GNU C++17 TESTS 69 420 37273600 2600
68460304 RedStone D Jan. 9, 2020, 5:50 p.m. OK GNU C++17 TESTS 69 468 123596800 2600
68460192 RedStone D Jan. 9, 2020, 5:48 p.m. OK GNU C++17 TESTS 69 592 243814400 2600
49677815 the_timur D Feb. 9, 2019, 9:10 p.m. OK GNU C++17 TESTS 69 623 81920000 2600
58862382 NoNameTemp-ly D Aug. 15, 2019, 12:07 p.m. OK GNU C++17 TESTS 69 624 69324800 2600
38458875 aminul D May 20, 2018, 12:06 p.m. OK Java 8 TESTS 69 701 4198400 2600
38458680 aminul D May 20, 2018, 11:59 a.m. OK Java 8 TESTS 69 733 14438400 2600
67404814 I_love_Harpae D Dec. 22, 2019, 5:53 a.m. OK Java 8 TESTS 69 1403 12800000 2600
67647083 I_love_Harpae D Dec. 26, 2019, 10:37 a.m. OK Java 8 TESTS 69 1434 248012800 2600
62170395 beginner1010 D Oct. 9, 2019, 12:07 a.m. OK Java 8 TESTS 69 3244 223539200 2600
67647363 I_love_Harpae D Dec. 26, 2019, 10:43 a.m. OK Java 8 TESTS 69 3540 247910400 2600
53785611 mennafadali D May 5, 2019, 10:01 a.m. OK Java 8 TESTS 69 3602 258048000 2600
35797018 jport D Feb. 28, 2018, 9:21 p.m. OK Java 8 TESTS 69 3743 260812800 2600
35796981 jport D Feb. 28, 2018, 9:19 p.m. OK Java 8 TESTS 69 3775 246272000 2600
67647132 I_love_Harpae D Dec. 26, 2019, 10:38 a.m. OK Java 8 TESTS 69 3837 247910400 2600
43407411 vjudge1 D Sept. 25, 2018, 12:05 p.m. OK MS C++ TESTS 69 343 5939200 2600
57199567 vjudge4 D July 17, 2019, 1:18 p.m. OK MS C++ TESTS 69 1934 143052800 2600
57198190 123CYH123 D July 17, 2019, 12:54 p.m. OK MS C++ TESTS 69 1996 143052800 2600
57194023 vjudge5 D July 17, 2019, 11:36 a.m. OK MS C++ TESTS 69 2152 143052800 2600
67852096 vjudge2 D Dec. 29, 2019, 3:55 a.m. OK MS C++ 2017 TESTS 69 1949 162508800 2600

remove filters

Back to search problems