結果

問題 No.166 マス埋めゲーム
ユーザー kenkoooo
提出日時 2015-03-19 23:27:00
言語 Java
(openjdk 23)
結果
WA  
実行時間 -
コード長 383 bytes
コンパイル時間 2,070 ms
コンパイル使用メモリ 74,940 KB
実行使用メモリ 41,488 KB
最終ジャッジ日時 2024-06-28 23:17:40
合計ジャッジ時間 5,774 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1 WA * 1
other AC * 7 WA * 13
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		long H = sc.nextLong();
		long W = sc.nextLong();
		long N = sc.nextLong();
		long K = sc.nextLong();

		H %= N;
		W %= N;

		long all = H * N;
		all %= N;
		if(all==K){
			System.out.println("YES");
		}else {
			System.out.println("NO");
			
		}

	}
}
0