結果
問題 | No.48 ロボットの操縦 |
ユーザー |
|
提出日時 | 2018-11-01 14:37:34 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 32 ms / 5,000 ms |
コード長 | 463 bytes |
コンパイル時間 | 659 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 10,880 KB |
最終ジャッジ日時 | 2024-11-20 01:49:15 |
合計ジャッジ時間 | 2,162 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 25 |
ソースコード
import mathX, Y, L = [ int(input()) for i in range(3) ]order = 0if (Y,X) == (0,0):print(order)exit()if Y > 0 and X == 0:o_D = 0else:if Y >= 0:o_D = 1else:o_D = 2if Y == 0:o_Y = 0else:if abs(Y) > L:o_Y = math.ceil(abs(Y)/L)else:o_Y = 1if X == 0:o_X = 0else:if abs(X) > L:o_X = math.ceil(abs(X)/L)else:o_X = 1print(o_D + o_Y + o_X)