結果

問題 No.3678 しゃべりすぎた男
コンテスト
ユーザー LyricalMaestro
提出日時 2026-09-05 17:26:09
言語 PyPy3
(7.3.23)
コンパイル:
pypy3 -mpy_compile _filename_
実行:
pypy3 _filename_
結果
AC  
実行時間 62 ms / 2,000 ms
+ 704µs
コード長 455 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 225 ms
コンパイル使用メモリ 96,204 KB
実行使用メモリ 79,104 KB
最終ジャッジ日時 2026-09-05 17:26:17
合計ジャッジ時間 4,515 ms
ジャッジサーバーID
(参考情報)
judge5_0 / judge4_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 33
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code



def main():
    T = list(map(int ,input().split()))
    ans = 0
    flg = True
    for t in T:
        if flg:
            if t >= 0:
                ans += t
                if 6000 - ans >= 0:
                    print(6000 - ans)
                else:
                    print(-1)
            else:
                flg = False
                print(-1)
        else:
            print(-1)
      


if __name__ == "__main__":
    main()
#    main2()
0