結果

問題 No.48 ロボットの操縦
コンテスト
ユーザー RK Python
提出日時 2020-05-31 15:37:13
言語 Python3
(3.15.0 + numpy 2.5.4 + scipy 1.18.1 + ACL)
コンパイル:
python3 -mpy_compile _filename_
実行:
python3 _filename_
結果
WA  
実行時間 -
コード長 353 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 54 ms
コンパイル使用メモリ 14,848 KB
実行使用メモリ 11,008 KB
最終ジャッジ日時 2026-09-25 10:27:39
合計ジャッジ時間 1,931 ms
ジャッジサーバーID
(参考情報)
judge4_0 / judge2_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 8 WA * 17
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

from math import ceil
X = int(input())
Y = int(input())
L = int(input())
if Y >= 0:
    if X!=0 and Y!=0:
        print(abs(ceil(X/L)) + abs(ceil(Y/L)) + 1)
    else:
        print(abs(ceil(X/L)) + abs(ceil(Y/L)))
else:
    if X!=0 and Y!=0:
        print(abs(ceil(X/L)) + abs(ceil(Y/L)) + 3)
    else:
        print(abs(ceil(X/L)) + abs(ceil(Y/L)) + 2)
0