結果

問題 No.410 出会い
ユーザー fkwnw3_1243fkwnw3_1243
提出日時 2017-05-03 16:46:46
言語 Java19
(openjdk 21)
結果
AC  
実行時間 43 ms / 2,000 ms
コード長 722 bytes
コンパイル時間 2,106 ms
コンパイル使用メモリ 72,484 KB
実行使用メモリ 49,380 KB
最終ジャッジ日時 2023-09-10 20:17:07
合計ジャッジ時間 4,090 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 42 ms
49,224 KB
testcase_01 AC 42 ms
49,212 KB
testcase_02 AC 43 ms
49,092 KB
testcase_03 AC 41 ms
49,088 KB
testcase_04 AC 42 ms
48,948 KB
testcase_05 AC 42 ms
49,176 KB
testcase_06 AC 41 ms
48,944 KB
testcase_07 AC 41 ms
48,948 KB
testcase_08 AC 41 ms
49,008 KB
testcase_09 AC 41 ms
49,184 KB
testcase_10 AC 42 ms
49,188 KB
testcase_11 AC 42 ms
49,216 KB
testcase_12 AC 42 ms
49,080 KB
testcase_13 AC 42 ms
49,380 KB
testcase_14 AC 42 ms
49,372 KB
testcase_15 AC 42 ms
49,072 KB
testcase_16 AC 42 ms
48,968 KB
testcase_17 AC 42 ms
49,184 KB
testcase_18 AC 42 ms
48,808 KB
testcase_19 AC 42 ms
49,068 KB
testcase_20 AC 43 ms
48,812 KB
testcase_21 AC 42 ms
48,992 KB
testcase_22 AC 42 ms
49,012 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.stream.Stream;

import static java.lang.System.in;

public class Main {
    public static void main(String[] args) throws IOException {
        BufferedReader reader = new BufferedReader(new InputStreamReader(in));
        String[] inputs = reader.readLine().split(" ");
        int px = Integer.parseInt(inputs[0]);
        int py = Integer.parseInt(inputs[1]);
        inputs = reader.readLine().split(" ");
        int qx = Integer.parseInt(inputs[0]);
        int qy = Integer.parseInt(inputs[1]);

        System.out.println((Math.abs(px - qx) + Math.abs(py - qy)) / 2.0);

    }
}
0