Submission #735972
Source Code Expand
#!/usr/bin/env python
# -*- coding: utf-8 -*-
L, X, Y, S, D = map(int, raw_input().split())
if X >= Y:
print (1. * (D + L - S) % L) / (Y + X)
else:
print min((1. * (D + L - S) % L) / (Y + X),
(1. * (S + L - D) % L) / (Y - X))
Submission Info
| Submission Time | |
|---|---|
| Task | A - 動く歩道 |
| User | gamma1129 |
| Language | Python (2.7.6) |
| Score | 100 |
| Code Size | 260 Byte |
| Status | AC |
| Exec Time | 1173 ms |
| Memory | 3720 KiB |
Judge Result
| Set Name | Sample | All | ||||
|---|---|---|---|---|---|---|
| Score / Max Score | 0 / 0 | 100 / 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 |
| Case Name | Status | Exec Time | Memory |
|---|---|---|---|
| 01.txt | AC | 1173 ms | 3720 KiB |
| 02.txt | AC | 25 ms | 2568 KiB |
| 03.txt | AC | 26 ms | 2568 KiB |
| 04.txt | AC | 26 ms | 2568 KiB |
| 05.txt | AC | 25 ms | 2568 KiB |
| 06.txt | AC | 27 ms | 2568 KiB |
| 07.txt | AC | 26 ms | 2568 KiB |
| 08.txt | AC | 27 ms | 2568 KiB |
| 09.txt | AC | 26 ms | 2568 KiB |
| 10.txt | AC | 26 ms | 2568 KiB |
| 11.txt | AC | 27 ms | 2568 KiB |
| 12.txt | AC | 27 ms | 2568 KiB |
| 13.txt | AC | 27 ms | 2568 KiB |
| 14.txt | AC | 27 ms | 2568 KiB |
| 15.txt | AC | 26 ms | 2568 KiB |
| 16.txt | AC | 27 ms | 2568 KiB |
| sample_01.txt | AC | 27 ms | 2568 KiB |
| sample_02.txt | AC | 26 ms | 2568 KiB |
| sample_03.txt | AC | 26 ms | 2568 KiB |
| sample_04.txt | AC | 26 ms | 2568 KiB |