結果

問題 No.156 キャンディー・ボックス
ユーザー yohei-kuyohei-ku
提出日時 2018-03-28 00:24:54
言語 Python2
(2.7.18)
結果
WA  
実行時間 -
コード長 226 bytes
コンパイル時間 66 ms
コンパイル使用メモリ 6,712 KB
実行使用メモリ 6,140 KB
最終ジャッジ日時 2023-09-07 19:15:20
合計ジャッジ時間 1,650 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 11 ms
6,048 KB
testcase_01 WA -
testcase_02 AC 11 ms
5,856 KB
testcase_03 AC 11 ms
5,896 KB
testcase_04 AC 11 ms
5,984 KB
testcase_05 AC 10 ms
5,892 KB
testcase_06 AC 12 ms
6,040 KB
testcase_07 AC 11 ms
5,892 KB
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 AC 11 ms
5,932 KB
testcase_15 AC 11 ms
6,000 KB
testcase_16 AC 11 ms
6,112 KB
testcase_17 AC 11 ms
5,884 KB
testcase_18 WA -
testcase_19 WA -
testcase_20 AC 11 ms
5,884 KB
testcase_21 AC 11 ms
5,936 KB
testcase_22 WA -
testcase_23 WA -
testcase_24 AC 10 ms
5,968 KB
testcase_25 AC 11 ms
5,856 KB
testcase_26 AC 11 ms
6,120 KB
testcase_27 AC 11 ms
5,936 KB
testcase_28 WA -
testcase_29 AC 11 ms
6,104 KB
testcase_30 WA -
testcase_31 WA -
testcase_32 AC 10 ms
5,888 KB
testcase_33 AC 11 ms
6,044 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N,M =map(int,raw_input().split())
C = list(map(int,raw_input().split()))
D,cnt =[],0
D = C[0]-M
if D <= 0:
    cnt += 1
for i in range(1,N):
    D = C[1]-abs(D)
    if D <= 0:
        cnt += 1
    else:
        break
print cnt
0