結果

問題 No.410 出会い
ユーザー kohaku_kohakukohaku_kohaku
提出日時 2016-11-10 02:23:38
言語 Java21
(openjdk 21)
結果
AC  
実行時間 132 ms / 2,000 ms
コード長 370 bytes
コンパイル時間 2,084 ms
コンパイル使用メモリ 71,560 KB
実行使用メモリ 55,968 KB
最終ジャッジ日時 2023-09-10 20:13:15
合計ジャッジ時間 6,125 ms
ジャッジサーバーID
(参考情報)
judge13 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 128 ms
55,632 KB
testcase_01 AC 127 ms
55,964 KB
testcase_02 AC 125 ms
55,368 KB
testcase_03 AC 125 ms
55,632 KB
testcase_04 AC 126 ms
53,384 KB
testcase_05 AC 129 ms
55,896 KB
testcase_06 AC 128 ms
53,656 KB
testcase_07 AC 127 ms
55,968 KB
testcase_08 AC 128 ms
55,876 KB
testcase_09 AC 127 ms
55,408 KB
testcase_10 AC 125 ms
55,944 KB
testcase_11 AC 127 ms
55,748 KB
testcase_12 AC 127 ms
55,772 KB
testcase_13 AC 126 ms
55,660 KB
testcase_14 AC 125 ms
55,676 KB
testcase_15 AC 125 ms
55,872 KB
testcase_16 AC 125 ms
55,340 KB
testcase_17 AC 127 ms
55,672 KB
testcase_18 AC 127 ms
55,404 KB
testcase_19 AC 127 ms
55,700 KB
testcase_20 AC 127 ms
55,440 KB
testcase_21 AC 126 ms
55,524 KB
testcase_22 AC 132 ms
55,732 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int Px = sc.nextInt();
        int Py = sc.nextInt();
        int Qx = sc.nextInt();
        int Qy = sc.nextInt();
        int d = Math.abs(Px-Qx) + Math.abs(Py-Qy);
        double r = d/2.0;
        System.out.println(r);
    }
}
0