結果

問題 No.166 マス埋めゲーム
ユーザー matsuyoshi30matsuyoshi30
提出日時 2016-02-10 22:23:46
言語 Java21
(openjdk 21)
結果
AC  
実行時間 119 ms / 1,000 ms
コード長 421 bytes
コンパイル時間 1,987 ms
コンパイル使用メモリ 78,800 KB
実行使用メモリ 57,548 KB
最終ジャッジ日時 2023-10-21 22:36:03
合計ジャッジ時間 5,036 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 105 ms
56,096 KB
testcase_01 AC 119 ms
57,548 KB
testcase_02 AC 117 ms
57,532 KB
testcase_03 AC 102 ms
56,176 KB
testcase_04 AC 116 ms
57,228 KB
testcase_05 AC 112 ms
57,316 KB
testcase_06 AC 102 ms
56,196 KB
testcase_07 AC 97 ms
55,696 KB
testcase_08 AC 112 ms
57,056 KB
testcase_09 AC 102 ms
56,196 KB
testcase_10 AC 109 ms
57,080 KB
testcase_11 AC 111 ms
57,092 KB
testcase_12 AC 104 ms
56,192 KB
testcase_13 AC 103 ms
56,172 KB
testcase_14 AC 110 ms
57,200 KB
testcase_15 AC 115 ms
57,184 KB
testcase_16 AC 115 ms
57,256 KB
testcase_17 AC 113 ms
56,120 KB
testcase_18 AC 114 ms
57,384 KB
testcase_19 AC 108 ms
56,204 KB
testcase_20 AC 118 ms
57,044 KB
testcase_21 AC 113 ms
56,780 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

class Main {
    public static void main(String[] args) throws Exception {
        Scanner in = new Scanner(System.in);
        long h = in.nextLong();
        long w = in.nextLong();
        long n = in.nextLong();
        long k = in.nextLong();

        if((h*w) % n == k % n) {
            System.out.println("YES");
        } else { 
            System.out.println("NO");
        }
    }
}
0