結果
| 問題 | No.24 数当てゲーム | 
| コンテスト | |
| ユーザー |  takosama312 | 
| 提出日時 | 2016-01-31 20:39:16 | 
| 言語 | C#(csc) (csc 3.9.0) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 25 ms / 5,000 ms | 
| コード長 | 1,385 bytes | 
| コンパイル時間 | 777 ms | 
| コンパイル使用メモリ | 108,428 KB | 
| 実行使用メモリ | 26,100 KB | 
| 最終ジャッジ日時 | 2024-09-21 19:44:07 | 
| 合計ジャッジ時間 | 1,652 ms | 
| ジャッジサーバーID (参考情報) | judge3 / judge4 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 10 | 
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace N
{
    class P
    {
        static void Main(string[] args)
        {
            int N = int.Parse(Console.ReadLine());
            string[] a;
            bool[] Ans = new bool[10] ;
            for(int i=0;i<10;i++)
            {
                Ans[i] = true;
            }
            for(int i=0;i<N;i++)
            {
                a= Console.ReadLine().Split();
                if(a[4]=="NO")
                {
                    Ans[int.Parse(a[0])] = false;
                    Ans[int.Parse(a[1])] = false;
                    Ans[int.Parse(a[2])] = false;
                    Ans[int.Parse(a[3])] = false;
                 }
                else
                {
                    for(int j=0;j<10;j++)
                    {
                        if(!(j==int.Parse(a[0])|| j == int.Parse(a[1])|| j == int.Parse(a[2])|| j == int.Parse(a[3])))
                        {
                            Ans[j] = false;
                        }
                    }
                }
            }
            for(int i=0;i<10;i++)
            {
                if(Ans[i])
                {
                    Console.WriteLine(i);
                    break;
                }
            }
            Console.ReadKey();
        }
    }
}
            
            
            
        