結果
| 問題 | No.48 ロボットの操縦 |
| コンテスト | |
| ユーザー |
Tsukasa_Type
|
| 提出日時 | 2018-02-09 14:37:50 |
| 言語 | Java (openjdk 26.0.2.1 + ACL) |
| 結果 |
WA
不安定
|
| 実行時間 | - |
| コード長 | 370 bytes |
| 記録 | |
| コンパイル時間 | 3,797 ms |
| コンパイル使用メモリ | 84,696 KB |
| 実行使用メモリ | 42,624 KB |
| 最終ジャッジ日時 | 2026-09-11 05:39:25 |
| 合計ジャッジ時間 | 5,615 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 17 WA * 8 |
ソースコード
import java.util.*;
public class Main {
static Scanner sc = new Scanner(System.in);
public static void main(String[] args) {
int x = Math.abs(sc.nextInt());
int y = Math.abs(sc.nextInt());
int leng = sc.nextInt();
int times = (x+leng-1)/leng + (y+leng-1)/leng;
if (y < 0) {times += 2;}
else if (y>0 && x!=0) {times += 1;}
System.out.println(times);
}
}
Tsukasa_Type