結果

問題 No.48 ロボットの操縦
ユーザー szkhts
提出日時 2020-05-05 12:10:39
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 284 bytes
コンパイル時間 85 ms
コンパイル使用メモリ 12,416 KB
実行使用メモリ 10,880 KB
最終ジャッジ日時 2024-06-26 06:07:56
合計ジャッジ時間 1,756 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 10 WA * 15
権限があれば一括ダウンロードができます

ソースコード

diff #

import math

X = int(input())
Y = int(input())
L = int(input())

distance = 0

if X != 0:
    distance += math.ceil(abs(X) / L) + 1

if Y != 0:
    distance += math.ceil(abs(Y) / L)

if  X != 0 and Y != 0:
    distance += 1
    
if X == 0 and Y < 0:
    distance += 2

print(distance)
0