結果

問題 No.1992 Tendon Walk
ユーザー ああいいああいい
提出日時 2022-07-01 21:27:55
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 39 ms / 2,000 ms
コード長 220 bytes
コンパイル時間 165 ms
コンパイル使用メモリ 82,032 KB
実行使用メモリ 53,688 KB
最終ジャッジ日時 2024-05-04 15:32:47
合計ジャッジ時間 969 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 39 ms
53,072 KB
testcase_01 AC 38 ms
52,936 KB
testcase_02 AC 33 ms
52,744 KB
testcase_03 AC 34 ms
52,012 KB
testcase_04 AC 34 ms
52,612 KB
testcase_05 AC 32 ms
52,852 KB
testcase_06 AC 34 ms
52,432 KB
testcase_07 AC 35 ms
53,088 KB
testcase_08 AC 36 ms
53,688 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

l = [2,2,-1,-1,2,-1,-1]
x = int(input())

ans = 0
import sys
now = 0
for _ in range(100):
    for a in l:
        now += a
        ans += abs(a)
        if now == x:
            print(ans)
            exit()
            
0