Russian Code Cup 2016 - Finals [Unofficial Mirror, Div. 1 Only Recommended]

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
720 Russian Code Cup 2016 - Finals [Unofficial Mirror, Div. 1 Only Recommended] FINISHED False 7200 302208923 Sept. 18, 2016, 11:05 a.m.

Problems

Solved
Index
Name
Type
Tags
Community Tag
Rating
( 330 ) D Slalom PROGRAMMING data structures dp sortings 3100

Little girl Masha likes winter sports, today she's planning to take part in slalom skiing. The track is represented as a grid composed of n × m squares. There are rectangular obstacles at the track, composed of grid squares. Masha must get from the square (1, 1) to the square ( n , m ) . She can move from a square to adjacent square: either to the right, or upwards. If the square is occupied by an obstacle, it is not allowed to move to that square. One can see that each obstacle can actually be passed in two ways: either it is to the right of Masha's path, or to the left. Masha likes to try all ways to do things, so she would like to know how many ways are there to pass the track. Two ways are considered different if there is an obstacle such that it is to the right of the path in one way, and to the left of the path in the other way. Help Masha to find the number of ways to pass the track. The number of ways can be quite big, so Masha would like to know it modulo 10 9 + 7 . The pictures below show different ways to pass the track in sample tests. The first line of input data contains three positive integers: n , m and k ( 3 ≤ n , m ≤ 10 6 , 0 ≤ k ≤ 10 5 ) — the size of the track and the number of obstacles. The following k lines contain four positive integers each: x 1 , y 1 , x 2 , y 2 ( 1 ≤ x 1 ≤ x 2 ≤ n , 1 ≤ y 1 ≤ y 2 ≤ m ) — coordinates of bottom left, and top right squares of the obstacle. It is guaranteed that there are no obstacles at squares (1, 1) and ( n , m ) , and no obstacles overlap (but some of them may touch). Output one integer — the number of ways to pass the track modulo 10 9 + 7 .

Tutorials

Russian Code Cup 2016 — Results and Tutorial

Submissions

Submission Id
Author(s)
Index
Submitted
Verdict
Language
Test Set
Tests Passed
Time taken (ms)
Memory Consumed (bytes)
Tags
Rating
33157902 Thefinal D Dec. 12, 2017, 2:35 p.m. OK GNU C++ TESTS 59 202 53555200 3100
26121711 Jin_Haonan D April 4, 2017, 12:26 p.m. OK GNU C++ TESTS 59 233 64512000 3100
26409602 tlzmybm D April 16, 2017, 9:34 a.m. OK GNU C++ TESTS 59 234 52428800 3100
21208022 LAGBOYDaD3zZ D Oct. 5, 2016, 12:24 p.m. OK GNU C++ TESTS 59 264 50380800 3100
27819708 xiqiao D June 16, 2017, 7:50 a.m. OK GNU C++ TESTS 59 280 51302400 3100
34350568 wdyhy D Jan. 20, 2018, 11:30 a.m. OK GNU C++ TESTS 59 280 86016000 3100
20769271 AkaneSasu D Sept. 20, 2016, 6:20 a.m. OK GNU C++ TESTS 59 312 50380800 3100
21258097 returnzoo D Oct. 7, 2016, 12:56 p.m. OK GNU C++ TESTS 59 358 57241600 3100
21351858 Los_Angelos_Laycurse D Oct. 11, 2016, 6:18 a.m. OK GNU C++ TESTS 59 373 38092800 3100
21351839 Los_Angelos_Laycurse D Oct. 11, 2016, 6:17 a.m. OK GNU C++ TESTS 59 389 55500800 3100
56885514 Steven_Meng D July 12, 2019, 12:24 p.m. OK GNU C++11 TESTS 59 187 99430400 3100
56885345 Okasaki_Ushio D July 12, 2019, 12:20 p.m. OK GNU C++11 TESTS 59 187 99430400 3100
47887284 adoubiq D Jan. 4, 2019, 1:34 a.m. OK GNU C++11 TESTS 59 217 50176000 3100
61776233 luogu_bot2 D Oct. 3, 2019, 11:51 a.m. OK GNU C++11 TESTS 59 217 52940800 3100
55813729 dyxg D June 20, 2019, 5:25 a.m. OK GNU C++11 TESTS 59 217 70553600 3100
40983590 ReaLNero1 D July 30, 2018, 6:56 p.m. OK GNU C++11 TESTS 59 233 43724800 3100
20776093 GEOTCBRL D Sept. 20, 2016, 12:55 p.m. OK GNU C++11 TESTS 59 233 43724800 3100
26406595 Manchery D April 16, 2017, 7:06 a.m. OK GNU C++11 TESTS 59 233 73523200 3100
58218366 Rockyyh D Aug. 3, 2019, 11:38 a.m. OK GNU C++11 TESTS 59 234 77004800 3100
56885781 Okasaki_Ushio D July 12, 2019, 12:30 p.m. OK GNU C++11 TESTS 59 234 99430400 3100
51605119 molamola. D March 21, 2019, 6:59 a.m. OK GNU C++14 TESTS 59 312 50585600 3100
47889506 lxlxl D Jan. 4, 2019, 4:55 a.m. OK GNU C++14 TESTS 59 327 50585600 3100
47890056 superguymj D Jan. 4, 2019, 5:32 a.m. OK GNU C++14 TESTS 59 343 50585600 3100
23511989 ShallWe D Jan. 3, 2017, 7:49 a.m. OK GNU C++14 TESTS 59 343 55705600 3100
27536765 zimpha D June 3, 2017, 5:45 a.m. OK GNU C++14 TESTS 59 358 65843200 3100
35811565 CQzhangyu D March 1, 2018, 12:45 p.m. OK GNU C++14 TESTS 59 390 54784000 3100
22482077 NiroBC D Nov. 25, 2016, 4:21 a.m. OK GNU C++14 TESTS 59 420 62054400 3100
20770184 Philipsweng D Sept. 20, 2016, 7:36 a.m. OK GNU C++14 TESTS 59 420 79257600 3100
21229732 LAGBOYDaD3zZ D Oct. 6, 2016, 8:41 a.m. OK GNU C++14 TESTS 59 499 115609600 3100
37890708 ckodser D May 4, 2018, 7:44 p.m. OK GNU C++14 TESTS 59 545 110080000 3100
51539445 vintage_Vlad_Makeev orz D March 19, 2019, 5:50 p.m. OK GNU C++17 TESTS 59 311 28364800 3100
57120783 Benq D July 16, 2019, 12:50 a.m. OK GNU C++17 TESTS 59 311 41062400 3100
53797372 w0nsh D May 5, 2019, 4:03 p.m. OK GNU C++17 TESTS 59 327 25088000 3100
40980382 ko_osaga D July 30, 2018, 5:30 p.m. OK GNU C++17 TESTS 59 327 51302400 3100
56997644 luogu_bot1 D July 14, 2019, 12:40 a.m. OK GNU C++17 TESTS 59 327 71680000 3100
56997642 ygy D July 14, 2019, 12:40 a.m. OK GNU C++17 TESTS 59 327 71680000 3100
56868120 Shayan.P D July 12, 2019, 4:46 a.m. OK GNU C++17 TESTS 59 389 68403200 3100
47952056 tkj D Jan. 5, 2019, 2:23 a.m. OK GNU C++17 TESTS 59 389 74240000 3100
37566885 khokho D April 24, 2018, 8:29 a.m. OK GNU C++17 TESTS 59 545 82022400 3100
22303904 roastbeef D Nov. 18, 2016, 10:04 a.m. OK Java 8 TESTS 59 1201 41881600 3100
21351864 Los_Angelos_Laycurse D Oct. 11, 2016, 6:18 a.m. OK MS C++ TESTS 59 420 38092800 3100

remove filters

Back to search problems