Submission #18529516
Source Code Expand
lines = input()
L, X, Y, S, D =map(int,lines.split())
rtime = 10000
rspeed = X+Y
if D >= S:
rtime = (D-S)/rspeed
else:
rtime = (L-(S-D))/rspeed
#反時計
ltime = 10000
if Y-X > 0:
lspeed = Y-X
if D >= S:
ltime = (L-(D-S))/lspeed
else:
ltime = (S-D)/lspeed
print(min(ltime,rtime))
Submission Info
| Submission Time | |
|---|---|
| Task | A - 動く歩道 |
| User | ofno |
| Language | Python (3.8.2) |
| Score | 0 |
| Code Size | 332 Byte |
| Status | RE |
| Exec Time | 28 ms |
| Memory | 8964 KiB |
Judge Result
| Set Name | Sample | All | ||||
|---|---|---|---|---|---|---|
| Score / Max Score | 0 / 0 | 0 / 100 | ||||
| Status |
|
|
| Set Name | Test Cases |
|---|---|
| Sample | sample_01.txt, sample_02.txt, sample_03.txt, sample_04.txt |
| All | 01.txt, 02.txt, 03.txt, 04.txt, 05.txt, 06.txt, 07.txt, 08.txt, 09.txt, 10.txt, 11.txt, 12.txt, 13.txt, 14.txt, 15.txt, 16.txt, sample_01.txt, sample_02.txt, sample_03.txt, sample_04.txt |
| Case Name | Status | Exec Time | Memory |
|---|---|---|---|
| 01.txt | RE | 26 ms | 8964 KiB |
| 02.txt | RE | 26 ms | 8812 KiB |
| 03.txt | RE | 18 ms | 8964 KiB |
| 04.txt | RE | 18 ms | 8708 KiB |
| 05.txt | RE | 20 ms | 8924 KiB |
| 06.txt | RE | 20 ms | 8788 KiB |
| 07.txt | RE | 18 ms | 8708 KiB |
| 08.txt | RE | 17 ms | 8776 KiB |
| 09.txt | RE | 19 ms | 8860 KiB |
| 10.txt | RE | 22 ms | 8820 KiB |
| 11.txt | RE | 19 ms | 8800 KiB |
| 12.txt | RE | 19 ms | 8708 KiB |
| 13.txt | RE | 21 ms | 8700 KiB |
| 14.txt | RE | 23 ms | 8808 KiB |
| 15.txt | RE | 21 ms | 8920 KiB |
| 16.txt | RE | 19 ms | 8704 KiB |
| sample_01.txt | RE | 20 ms | 8676 KiB |
| sample_02.txt | RE | 21 ms | 8804 KiB |
| sample_03.txt | RE | 28 ms | 8708 KiB |
| sample_04.txt | RE | 24 ms | 8800 KiB |