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 |
---|---|---|---|---|---|---|
1468 | 2020-2021 ICPC, NERC, Southern and Volga Russian Regional Contest (Online Mirror, ICPC Rules) | FINISHED | False | 18000 | 128456711 | Dec. 25, 2020, 11:35 a.m. |
Solved$ |
Index |
Name |
Type |
Tags |
Community Tag |
Rating |
---|---|---|---|---|---|---|
( 829 ) | G | Hobbits | PROGRAMMING | geometry |
B"The hobbits Frodo and Sam are carrying the One Ring to Mordor. In order not to be spotted by orcs, they decided to go through the mountains. The mountain relief can be represented as a polyline with n points (x_i, y_i) , numbered from 1 to n ( x_i < x_{i + 1} for 1 <= i <= n - 1 ). Hobbits start their journey at the point (x_1, y_1) and should reach the point (x_n, y_n) to complete their mission. The problem is that there is a tower with the Eye of Sauron, which watches them. The tower is located at the point (x_n, y_n) and has the height H , so the Eye is located at the point (x_n, y_n + H) . In order to complete the mission successfully, the hobbits have to wear cloaks all the time when the Sauron Eye can see them, i. xe2 x80 x89e. when there is a direct line from the Eye to the hobbits which is not intersected by the relief. The hobbits are low, so their height can be considered negligibly small, but still positive, so when a direct line from the Sauron Eye to the hobbits only touches the relief, the Eye can see them. The hobbits do not like to wear cloaks, so they wear them only when they can be spotted by the Eye. Your task is to calculate the total distance the hobbits have to walk while wearing cloaks. The first line of the input contains two integers n and H ( 2 <= n <= 2 cdot 10^5 ; 1 <= H <= 10^4 ) -- the number of vertices in polyline and the tower height. The next n lines contain two integers x_i, y_i each ( 0 <= x_i <= 4 cdot 10^5 ; 0 <= y_i <= 10^4 ) -- the coordinates of the polyline vertices. It is guaranteed that x_i < x_{i + 1} for 1 <= i <= n - 1 . Print one real number -- the total distance the hobbits have to walk while wearing cloaks. Your answer will be considered correct if its absolute or relative error does not exceed 10^{-6} -- formally, if your answer is a , and the jury's answer is b , you"... |
Tutorial (PDF) |
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
---|---|---|---|---|---|---|---|---|---|---|---|
102333378 | i_m_a | G | Dec. 25, 2020, 3:45 p.m. | OK | GNU C++11 | TESTS | 117 | 31 | 3174400 | ||
102330580 | ppc_qjd Mitsukasa_Ayase dysyn1314 | G | Dec. 25, 2020, 3:20 p.m. | OK | GNU C++11 | TESTS | 117 | 46 | 8089600 | ||
102325453 | dengyipeng jz_597 gmh77 | G | Dec. 25, 2020, 2:37 p.m. | OK | GNU C++11 | TESTS | 117 | 62 | 1433600 | ||
102318555 | C20191629 TiwAirOAO | G | Dec. 25, 2020, 1:42 p.m. | OK | GNU C++11 | TESTS | 117 | 62 | 1638400 | ||
102325843 | aymanrasheed7 serotonin Alpha_Q | G | Dec. 25, 2020, 2:40 p.m. | OK | GNU C++11 | TESTS | 117 | 78 | 3174400 | ||
102329794 | C20192413 Lucky_Glass | G | Dec. 25, 2020, 3:13 p.m. | OK | GNU C++11 | TESTS | 117 | 93 | 3788800 | ||
102359427 | Dan_zyc | G | Dec. 26, 2020, 1:16 a.m. | OK | GNU C++11 | TESTS | 117 | 124 | 6451200 | ||
102337618 | _blackjack_ yyqchemic hzy9819 | G | Dec. 25, 2020, 4:33 p.m. | OK | GNU C++11 | TESTS | 117 | 139 | 9420800 | ||
102335641 | BLUESKY007 | G | Dec. 25, 2020, 4:08 p.m. | OK | GNU C++11 | TESTS | 117 | 140 | 3174400 | ||
102332404 | fanache99 | G | Dec. 25, 2020, 3:36 p.m. | OK | GNU C++11 | TESTS | 117 | 202 | 1638400 | ||
102353363 | algodoer | G | Dec. 25, 2020, 9:01 p.m. | OK | GNU C++14 | TESTS | 117 | 93 | 3993600 | ||
102325501 | atodo BlueDiamond | G | Dec. 25, 2020, 2:37 p.m. | OK | GNU C++14 | TESTS | 117 | 109 | 1638400 | ||
102336293 | sfiction shb123 J.T.J.L. | G | Dec. 25, 2020, 4:17 p.m. | OK | GNU C++14 | TESTS | 117 | 109 | 6451200 | ||
102320938 | EternalAlexander Fuyuki ustze | G | Dec. 25, 2020, 2:01 p.m. | OK | GNU C++14 | TESTS | 117 | 109 | 16076800 | ||
102336230 | lucaperju ivan.tudor apostoldaniel854 | G | Dec. 25, 2020, 4:16 p.m. | OK | GNU C++14 | TESTS | 117 | 124 | 3174400 | ||
102330577 | bhvdsi Ashishgup | G | Dec. 25, 2020, 3:20 p.m. | OK | GNU C++14 | TESTS | 117 | 124 | 3174400 | ||
102346826 | Reiketsu | G | Dec. 25, 2020, 6:59 p.m. | OK | GNU C++14 | TESTS | 117 | 124 | 6451200 | ||
102328715 | Codingsince19 Shivam_18 karanagarwalla | G | Dec. 25, 2020, 3:04 p.m. | OK | GNU C++14 | TESTS | 117 | 124 | 6553600 | ||
102345925 | ShArt23 | G | Dec. 25, 2020, 6:46 p.m. | OK | GNU C++14 | TESTS | 117 | 139 | 9523200 | ||
102334072 | Nero | G | Dec. 25, 2020, 3:51 p.m. | OK | GNU C++14 | TESTS | 117 | 265 | 3174400 | ||
102337457 | Kanceroni Janjito911 Dorito911 | G | Dec. 25, 2020, 4:31 p.m. | OK | GNU C++17 | TESTS | 117 | 93 | 6348800 | ||
102336660 | Kanceroni Janjito911 Dorito911 | G | Dec. 25, 2020, 4:21 p.m. | OK | GNU C++17 | TESTS | 117 | 93 | 6348800 | ||
102334165 | milisav GiannisAntetokounmpo | G | Dec. 25, 2020, 3:52 p.m. | OK | GNU C++17 | TESTS | 117 | 93 | 16076800 | ||
102328251 | iaNTU | G | Dec. 25, 2020, 3 p.m. | OK | GNU C++17 | TESTS | 117 | 108 | 4812800 | ||
102325183 | LZHlzh q234rty Isrothy | G | Dec. 25, 2020, 2:35 p.m. | OK | GNU C++17 | TESTS | 117 | 109 | 3174400 | ||
102304613 | 251 jiangly MiFaFaOvO | G | Dec. 25, 2020, 11:55 a.m. | OK | GNU C++17 | TESTS | 117 | 109 | 4812800 | ||
102320381 | gisp_zjz Roundgod | G | Dec. 25, 2020, 1:57 p.m. | OK | GNU C++17 | TESTS | 117 | 109 | 16076800 | ||
102328489 | kefaa2 Fedosik | G | Dec. 25, 2020, 3:02 p.m. | OK | GNU C++17 | TESTS | 117 | 124 | 1843200 | ||
102328397 | kefaa2 Fedosik | G | Dec. 25, 2020, 3:02 p.m. | OK | GNU C++17 | TESTS | 117 | 124 | 1843200 | ||
102326382 | EndRay KostasKostil VladProg | G | Dec. 25, 2020, 2:44 p.m. | OK | GNU C++17 | TESTS | 117 | 124 | 3174400 | ||
102327925 | QAQAutoMaton PinkRabbit | G | Dec. 25, 2020, 2:57 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 31 | 7475200 | ||
102320464 | ainta | G | Dec. 25, 2020, 1:57 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 46 | 28672000 | ||
102331868 | natsugiri | G | Dec. 25, 2020, 3:32 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 62 | 3174400 | ||
102337406 | TheOneYouWant | G | Dec. 25, 2020, 4:30 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 77 | 1638400 | ||
102332483 | Kalptaru _baba_yaga Wernier | G | Dec. 25, 2020, 3:37 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 77 | 3174400 | ||
102328837 | hotman78 KKT_89 Hyado | G | Dec. 25, 2020, 3:05 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 77 | 3174400 | ||
102320079 | kshitij_sodani balbit errorgorn | G | Dec. 25, 2020, 1:54 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 77 | 3174400 | ||
102316680 | amsen Man Arpa | G | Dec. 25, 2020, 1:26 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 77 | 3174400 | ||
102333309 | dillion kai824 huangqr | G | Dec. 25, 2020, 3:44 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 77 | 4812800 | ||
102326400 | BigBag | G | Dec. 25, 2020, 2:44 p.m. | OK | GNU C++17 (64) | TESTS | 117 | 77 | 6451200 | ||
102334453 | DishonoredRighteous iakovlev.zakhar golikovnik | G | Dec. 25, 2020, 3:55 p.m. | OK | Java 8 | TESTS | 117 | 234 | 4403200 | ||
102351387 | sh1194 | G | Dec. 25, 2020, 8:18 p.m. | OK | PyPy 3 | TESTS | 117 | 452 | 19046400 | ||
102320173 | wow_ok FlakeLCR conqueror_of_tourist | G | Dec. 25, 2020, 1:55 p.m. | OK | PyPy 3 | TESTS | 117 | 498 | 19148800 | ||
102351521 | sh1194 | G | Dec. 25, 2020, 8:20 p.m. | OK | PyPy 3 | TESTS | 117 | 545 | 19046400 | ||
102325043 | sansen | G | Dec. 25, 2020, 2:34 p.m. | OK | Rust | TESTS | 117 | 62 | 7372800 | ||
102293939 | G | Dec. 25, 2020, 9:38 a.m. | OK | Unknown | TESTS | 0 | 0 | 0 | |||
102293925 | G | Dec. 25, 2020, 9:38 a.m. | OK | Unknown | TESTS | 0 | 0 | 0 | |||
102293885 | G | Dec. 25, 2020, 9:38 a.m. | OK | Unknown | TESTS | 0 | 0 | 0 | |||
102293819 | G | Dec. 25, 2020, 9:38 a.m. | OK | Unknown | TESTS | 0 | 0 | 0 | |||
102293780 | G | Dec. 25, 2020, 9:38 a.m. | OK | Unknown | TESTS | 0 | 0 | 0 | |||
102293618 | G | Dec. 25, 2020, 9:38 a.m. | OK | Unknown | TESTS | 0 | 0 | 0 | |||
102293461 | G | Dec. 25, 2020, 9:38 a.m. | OK | Unknown | TESTS | 0 | 0 | 0 |
Back to search problems