結果

問題 No.683 Two Operations No.3
ユーザー matsuyoshi30matsuyoshi30
提出日時 2018-05-11 22:40:26
言語 Java21
(openjdk 21)
結果
RE  
実行時間 -
コード長 403 bytes
コンパイル時間 3,306 ms
コンパイル使用メモリ 72,592 KB
実行使用メモリ 56,456 KB
最終ジャッジ日時 2023-09-10 17:37:57
合計ジャッジ時間 6,072 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 RE -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 RE -
testcase_05 RE -
testcase_06 RE -
testcase_07 RE -
testcase_08 RE -
testcase_09 RE -
testcase_10 RE -
testcase_11 RE -
testcase_12 RE -
testcase_13 RE -
testcase_14 RE -
testcase_15 RE -
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int a = in.nextInt();
        int b = in.nextInt();

        String ans = "YES";

        if(a == b && a != 0 && b != 0) ans = "NO";

        if(a % 2 != 0 && b % 2 != 0)
            if((a-b) % 2 == 0)
                ans = "NO";

        System.out.println(ans);
    }
}
0