結果

問題 No.740 幻の木
ユーザー kohei2019kohei2019
提出日時 2022-03-30 23:51:52
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 43 ms / 2,000 ms
コード長 159 bytes
コンパイル時間 179 ms
コンパイル使用メモリ 82,028 KB
実行使用メモリ 60,496 KB
最終ジャッジ日時 2024-04-27 13:42:27
合計ジャッジ時間 1,084 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 33 ms
52,340 KB
testcase_01 AC 36 ms
52,184 KB
testcase_02 AC 36 ms
52,956 KB
testcase_03 AC 36 ms
53,428 KB
testcase_04 AC 34 ms
53,104 KB
testcase_05 AC 31 ms
52,488 KB
testcase_06 AC 43 ms
60,496 KB
testcase_07 AC 32 ms
53,048 KB
testcase_08 AC 33 ms
52,792 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N,M,P,Q = map(int,input().split())
ans = 0
P -= 1
while N > 0:
    if P <= (ans % 12) < P+Q:
        N -= 2*M
    else: 
        N -= M
    ans += 1
print(ans)
0