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 |
|---|---|---|---|---|---|---|
| 1776 | SWERC 2022-2023 - Online Mirror (Unrated, ICPC Rules, Teams Preferred) | FINISHED | False | 18000 | 99600923 | Feb. 19, 2023, 11:05 a.m. |
Solved |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
|---|---|---|---|---|---|---|
| ( 107 ) | E | Crossing the Railways | PROGRAMMING | data structures dp |
Isona is in a train station. This station has two platforms, and between them there are (m) parallel railways that can be viewed as infinite straight lines. Each railway is identified with an integer from (1) to (m), railway (1) being the closest to the first platform and railway (m) being the farthest. There is a (1) meter distance between consecutive railways, as well as between each platform and its closest railway. Isona is standing on the inner border of the first platform, when she realizes that she forgot to validate her ticket! There is a validating machine on the second platform, exactly opposite her current position (thus, the distance between Isona and the validating machine is (m + 1) meters). There are only (s) seconds left to validate the ticket and the bridge designated to cross the railways is too far from the validating machine. Therefore, Isona (who is very brave and a little bit careless) will cross the railways running in a straight line perpendicular to the railways themselves. Isona can only run forward (not backward) and she can stay still . When she runs at maximum speed, she needs (v) seconds to traverse (1) meter. She can run at any speed less than or equal to her maximum speed. There is only one problem: (n) trains are programmed to transit through the railways. The (i)-th train will use the railway (r_i). It will start crossing the straight line between Isona and the validating machine (a_i) seconds from now and it will end (b_i) seconds from now. Of course, Isona cannot cross a railway when a train is passing. Formally, for every (i = 1, \, 2, \, \dots, \, n), Isona is not allowed to be on railway (r_i) at any time (t) with (a_i < t < b_i) (but she is allowed to cross at times (a_i) or (b_i)). The following picture summarizes the situation. In the picture there are (m = 4) railways and two trains are visible; the train going through railway |
No solutions yet.