結果

問題 No.85 TVザッピング(1)
ユーザー Himatsubushin
提出日時 2022-12-16 16:43:31
言語 C
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 334 bytes
コンパイル時間 162 ms
コンパイル使用メモリ 27,648 KB
実行使用メモリ 6,820 KB
最終ジャッジ日時 2024-11-15 21:43:27
合計ジャッジ時間 1,138 ms
ジャッジサーバーID
(参考情報)
judge5 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 26 WA * 1
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <stdio.h>

int main(int argc, const char * argv[]) {
  int m, n, c;
  
  scanf("%d %d %d", &n, &m, &c);
  
  if (n % 2 == 1 && m % 2 == 1)
    printf("NO\n");
  else if ((n == 1 && m == 2) || (m == 2 && n == 1))
    printf("YES\n");
  else if (n == 1 || m == 1)
    printf("NO\n");
  else
    printf("YES\n");

  return 0;
}
0