結果
| 問題 |
No.48 ロボットの操縦
|
| コンテスト | |
| ユーザー |
shirokuro9586
|
| 提出日時 | 2018-04-24 18:55:32 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 685 bytes |
| コンパイル時間 | 89 ms |
| コンパイル使用メモリ | 12,416 KB |
| 実行使用メモリ | 17,700 KB |
| 最終ジャッジ日時 | 2024-06-27 16:02:30 |
| 合計ジャッジ時間 | 6,758 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 2 WA * 1 TLE * 1 -- * 21 |
ソースコード
X = int(input())
Y = int(input())
L = int(input())
goal = [X, Y]
koudou = 0
if(Y > 0):#北
while(True):
if(Y <= 0):
break
Y -= L
koudou += 1
elif(Y < 0):#南
koudou += 1
while(True):
if(Y >= 0):
break
Y += L
koudou += 1
if(X > 0):#東
koudou += 1
while(True):
if(X <= 0):
break
X -= L
koudou += 1
elif(X < 0):#西
koudou += 1
while(True):
if(X >= 0):
break
X += L
koudou += 1
print(koudou)
shirokuro9586