結果
| 問題 | No.85 TVザッピング(1) |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2015-03-10 06:18:56 |
| 言語 | Go (1.25.5) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 732 bytes |
| 記録 | |
| コンパイル時間 | 12,645 ms |
| コンパイル使用メモリ | 248,824 KB |
| 実行使用メモリ | 7,852 KB |
| 最終ジャッジ日時 | 2026-01-01 17:49:20 |
| 合計ジャッジ時間 | 13,737 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 WA * 2 |
| other | AC * 8 WA * 19 |
ソースコード
package main
import (
"bufio"
"os"
"strconv"
"fmt"
)
var s = bufio.NewScanner(os.Stdin)
func next() string {
// s.Split(bufio.ScanWords) // 削除: Scan後に呼ぶとPanicになるため
s.Scan()
return s.Text()
}
func nextInt() int {
i, e := strconv.Atoi(next())
if e != nil {
panic(e)
}
return i
}
func nextLong() int64 {
i, e := strconv.ParseInt(next(), 10, 64)
if e != nil {
panic(e)
}
return i
}
func main() {
// Scan開始前にSplitを設定しないとPanicになるため、ここに移動
s.Split(bufio.ScanWords)
N := nextInt()
M := nextInt()
_ = nextInt()
out := "YES"
if N*M == 2 {
//nop
}else if (N%2 == 1 || M%2 == 1) {
fmt.Println("NO")
}else {
//nop
}
fmt.Println(out)
}