結果
問題 |
No.166 マス埋めゲーム
|
ユーザー |
![]() |
提出日時 | 2016-07-02 16:45:52 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 132 ms / 1,000 ms |
コード長 | 355 bytes |
コンパイル時間 | 2,035 ms |
コンパイル使用メモリ | 75,432 KB |
実行使用メモリ | 54,240 KB |
最終ジャッジ日時 | 2024-10-12 01:00:11 |
合計ジャッジ時間 | 6,094 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 20 |
ソースコード
import java.util.Scanner; public class Main{ public static void main(String[] args){ Scanner sc=new Scanner(System.in); while(sc.hasNext()){ long h=sc.nextLong(); long w=sc.nextLong(); long n=sc.nextLong(); long k=sc.nextLong(); if(((h*w)%n==0 ? n : (h*w)%n) == k) System.out.println("YES"); else System.out.println("NO"); } } }