結果

問題 No.85 TVザッピング(1)
ユーザー k_kadora
提出日時 2015-06-19 22:06:58
言語 Java
(openjdk 23)
結果
AC  
実行時間 132 ms / 5,000 ms
コード長 449 bytes
コンパイル時間 3,979 ms
コンパイル使用メモリ 74,472 KB
実行使用メモリ 41,472 KB
最終ジャッジ日時 2024-10-04 17:30:47
合計ジャッジ時間 8,257 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 27
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;
public class Yuki85{
	public static void main(String[] arg){
		Scanner sc = new Scanner(System.in);
		int n,m,c,res;
		n = sc.nextInt();
		m = sc.nextInt();
		c = sc.nextInt();
		res = n*m;
		if(res % 2 == 0){
			if(res == 2){
				System.out.println("YES");
			}else{
				if(n!=1 && m != 1){
					System.out.println("YES");
				}else{
					System.out.println("NO");
				}
			}
		}else{
			System.out.println("NO");
		}
	}
}
0