結果

問題 No.208 王将
ユーザー koheiarai94koheiarai94
提出日時 2017-09-25 01:46:14
言語 Java21
(openjdk 21)
結果
AC  
実行時間 122 ms / 1,000 ms
コード長 450 bytes
コンパイル時間 2,268 ms
コンパイル使用メモリ 71,756 KB
実行使用メモリ 56,516 KB
最終ジャッジ日時 2023-08-09 02:23:11
合計ジャッジ時間 6,461 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 118 ms
55,884 KB
testcase_01 AC 120 ms
55,848 KB
testcase_02 AC 118 ms
55,936 KB
testcase_03 AC 117 ms
55,660 KB
testcase_04 AC 118 ms
56,068 KB
testcase_05 AC 122 ms
55,364 KB
testcase_06 AC 119 ms
56,516 KB
testcase_07 AC 118 ms
56,036 KB
testcase_08 AC 119 ms
56,180 KB
testcase_09 AC 119 ms
56,384 KB
testcase_10 AC 117 ms
55,632 KB
testcase_11 AC 116 ms
55,800 KB
testcase_12 AC 114 ms
56,024 KB
testcase_13 AC 119 ms
55,748 KB
testcase_14 AC 118 ms
55,720 KB
testcase_15 AC 121 ms
55,832 KB
testcase_16 AC 119 ms
56,056 KB
testcase_17 AC 119 ms
55,820 KB
testcase_18 AC 118 ms
56,412 KB
testcase_19 AC 118 ms
56,440 KB
testcase_20 AC 118 ms
56,352 KB
testcase_21 AC 120 ms
55,656 KB
testcase_22 AC 120 ms
56,060 KB
testcase_23 AC 114 ms
56,464 KB
testcase_24 AC 116 ms
55,640 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

// Yuki 208
// https://yukicoder.me/problems/no/208

public class Main {
	
	public static void main (String[] args) throws InterruptedException {
		Scanner in = new Scanner(System.in);
		
		long x = in.nextLong();
		long y = in.nextLong();
		long x1 = in.nextLong();
		long y1 = in.nextLong();
		
		long answer = Math.max(x, y);
		if (x1 < x && y1 < y && x == y && x1 == y1) {
			answer++;
		}
		System.out.println(answer);
	}
}
0