結果
| 問題 | No.582 キャンディー・ボックス3 | 
| コンテスト | |
| ユーザー |  No | 
| 提出日時 | 2018-01-24 23:59:48 | 
| 言語 | C#(csc) (csc 3.9.0) | 
| 結果 | 
                                WA
                                 
                             | 
| 実行時間 | - | 
| コード長 | 660 bytes | 
| コンパイル時間 | 1,213 ms | 
| コンパイル使用メモリ | 106,752 KB | 
| 実行使用メモリ | 19,840 KB | 
| 最終ジャッジ日時 | 2024-12-26 08:26:07 | 
| 合計ジャッジ時間 | 2,819 ms | 
| ジャッジサーバーID (参考情報) | judge2 / judge5 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 12 WA * 5 | 
コンパイルメッセージ
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;
namespace y
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = int.Parse(Console.ReadLine());
            var c = Console.ReadLine().Split().Select(x => int.Parse(x)).ToArray();
            int z = c.Count(x => x == 0);
            int o = c.Count(x => x == 1);
            int t = c.Count(x => x == 2);
            n -= 0;
            string a = "";
            if (o == n && n % 2 == 1 && n != 1) a = "A";
            if (o == n - 1 && t == 1 && n % 2 == 0) a = "A";
            else a = "B";
            Console.WriteLine(a);
            Console.ReadLine();
        }
    }
}
            
            
            
        