結果

問題 No.48 ロボットの操縦
ユーザー mlihua09
提出日時 2020-08-23 01:27:52
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 45 ms / 5,000 ms
コード長 262 bytes
コンパイル時間 176 ms
コンパイル使用メモリ 81,792 KB
実行使用メモリ 52,096 KB
最終ジャッジ日時 2024-10-15 12:30:28
合計ジャッジ時間 2,095 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 25
権限があれば一括ダウンロードができます

ソースコード

diff #


import math



X = int(input())

Y = int(input())

L = int(input())

ans = math.ceil(abs(X) / L) + math.ceil(abs(Y) / L)

if Y < 0:
    
    print(ans + 2)
    
else:
    if X == 0:
        
        print(ans)
        
    else:
        
        print(ans + 1)
0