結果
| 問題 | 
                            No.48 ロボットの操縦
                             | 
                    
| コンテスト | |
| ユーザー | 
                             D4prog
                         | 
                    
| 提出日時 | 2016-05-30 20:33:31 | 
| 言語 | Lua  (LuaJit 2.1.1734355927)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 215 bytes | 
| コンパイル時間 | 271 ms | 
| コンパイル使用メモリ | 6,948 KB | 
| 実行使用メモリ | 6,820 KB | 
| 最終ジャッジ日時 | 2024-10-07 19:27:26 | 
| 合計ジャッジ時間 | 842 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge1 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 24 WA * 1 | 
ソースコード
x, y, l = io.read("*n"), io.read("*n"), io.read("*n")
turn = 1;
if (y > 0) and (x == 0) then turn = 0 end
if (y < 0) then turn = 2 end
fw = function(n) return math.ceil(math.abs(n)/l) end
print(turn + fw(x) + fw(y))
            
            
            
        
            
D4prog