結果

問題 No.48 ロボットの操縦
ユーザー 田山悠人
提出日時 2022-04-26 14:07:33
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 687 bytes
コンパイル時間 118 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 10,624 KB
最終ジャッジ日時 2024-06-28 07:28:24
合計ジャッジ時間 1,699 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other WA * 25
権限があれば一括ダウンロードができます

ソースコード

diff #

def main():

    inp = [input() for i in range(3)]

    long = [int(inp[0]), int(inp[1])]
    

    count1 = 0
    K1 = [int(0), int(inp[2])]
    for (i, j) in zip(long, K1):
        g1 = i -j
        count1 = count1 + 1
        if g1 <= 0:
            break

    count2 = 0
    K2 = [int(inp[2]), int(0)]
    for (i, j) in zip(long, K2):
        g2 = i - j
        count2 = count2 + 1
        if g2 <= 0:
            break

    if inp[0] == 0: 
        a = 0
    else:
        a = 1
    
    if inp[1] == 0:
        b = 0
    elif inp[0] == 0:
        b =0
    elif inp[0] == 0 and inp[1] < 0:
        b = 2
    else:
        b = 1
    
    ans = count1 + count2 + a + b
    print(ans)
0