結果
問題 |
No.166 マス埋めゲーム
|
ユーザー |
![]() |
提出日時 | 2015-03-19 23:48:18 |
言語 | Java (openjdk 23) |
結果 |
WA
|
実行時間 | - |
コード長 | 384 bytes |
コンパイル時間 | 2,058 ms |
コンパイル使用メモリ | 74,532 KB |
実行使用メモリ | 56,264 KB |
最終ジャッジ日時 | 2024-06-28 23:23:50 |
合計ジャッジ時間 | 5,011 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 WA * 1 |
other | AC * 17 WA * 3 |
ソースコード
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 * W; all %= N; if (all == K) { System.out.println("YES"); } else { System.out.println("NO"); } } }