結果
| 問題 |
No.870 無敵囲い
|
| コンテスト | |
| ユーザー |
ngtkana
|
| 提出日時 | 2020-02-06 12:24:44 |
| 言語 | C#(csc) (csc 3.9.0) |
| 結果 |
AC
|
| 実行時間 | 28 ms / 300 ms |
| コード長 | 569 bytes |
| コンパイル時間 | 2,409 ms |
| コンパイル使用メモリ | 105,216 KB |
| 実行使用メモリ | 19,072 KB |
| 最終ジャッジ日時 | 2024-06-29 06:37:27 |
| 合計ジャッジ時間 | 2,169 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 18 |
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System;
using System.Linq;
using System.Collections.Generic;
static class NagataKanaIsAGenius {
public static void Main() {
int[,]ckd=new int[11,11];
ckd[2,8]=1;
ckd[3,9]=2;
ckd[7,9]=3;
int n=int.Parse(Console.ReadLine());
for(int i=0;i<n;i++){
int[]a=Console.ReadLine().Split().Select(int.Parse).ToArray();
int x=ckd[a[0],a[1]];
ckd[a[0],a[1]]=0;
ckd[a[2],a[3]]=x;
}
Console.WriteLine(ckd[5,8]==1&&ckd[4,8]==2&&ckd[6,8]==3?"YES":"NO");
}
}
ngtkana