結果
問題 | No.450 ベー君のシャトルラン |
ユーザー |
![]() |
提出日時 | 2025-03-20 21:14:27 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 39 ms / 2,000 ms |
コード長 | 396 bytes |
コンパイル時間 | 178 ms |
コンパイル使用メモリ | 81,952 KB |
実行使用メモリ | 53,724 KB |
最終ジャッジ日時 | 2025-03-20 21:15:12 |
合計ジャッジ時間 | 1,832 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 20 |
ソースコード
vl, vr = map(int, input().split())d = int(input())w = int(input())total_time = d / (vl + vr)total_distance = w * total_time# Formatting the output to have up to 10 decimal places and removing trailing zerosformatted_output = "{0:.10f}".format(total_distance).rstrip('0').rstrip('.') if '.' in "{0:.10f}".format(total_distance) else "{0:.0f}".format(total_distance)print(formatted_output)