結果
問題 | No.1486 ロボット |
ユーザー |
![]() |
提出日時 | 2021-08-31 22:38:48 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 53 ms / 2,000 ms |
コード長 | 401 bytes |
コンパイル時間 | 195 ms |
コンパイル使用メモリ | 82,048 KB |
実行使用メモリ | 61,568 KB |
最終ジャッジ日時 | 2024-11-26 09:35:41 |
合計ジャッジ時間 | 1,884 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 17 |
ソースコード
a,b,c,d,e = map(int,input().split()) cou = 0 if (a+b)*(c+d) > e: for i in range(e): if i % (a+b) < a and i % (c+d) < c: cou += 1 else: for i in range((a+b)*(c+d)): if i % (a+b) < a and i % (c+d) < c: cou += 1 cou *= e // ((a+b)*(c+d)) for i in range(e % ((a+b)*(c+d))): if i % (a+b) < a and i % (c+d) < c: cou += 1 print(cou)