結果

問題 No.349 干支の置き物
ユーザー tasukutasuku
提出日時 2016-03-12 02:17:57
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 65 ms / 2,000 ms
コード長 684 bytes
コンパイル時間 3,745 ms
コンパイル使用メモリ 104,332 KB
実行使用メモリ 25,744 KB
最終ジャッジ日時 2023-08-10 21:37:56
合計ジャッジ時間 6,935 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 60 ms
21,692 KB
testcase_01 AC 59 ms
21,756 KB
testcase_02 AC 59 ms
21,828 KB
testcase_03 AC 60 ms
21,660 KB
testcase_04 AC 58 ms
21,768 KB
testcase_05 AC 59 ms
21,652 KB
testcase_06 AC 60 ms
23,716 KB
testcase_07 AC 62 ms
23,680 KB
testcase_08 AC 59 ms
21,608 KB
testcase_09 AC 58 ms
21,652 KB
testcase_10 AC 60 ms
21,844 KB
testcase_11 AC 59 ms
21,772 KB
testcase_12 AC 61 ms
19,604 KB
testcase_13 AC 62 ms
21,744 KB
testcase_14 AC 61 ms
21,652 KB
testcase_15 AC 60 ms
21,812 KB
testcase_16 AC 60 ms
21,704 KB
testcase_17 AC 62 ms
23,736 KB
testcase_18 AC 59 ms
19,736 KB
testcase_19 AC 60 ms
21,696 KB
testcase_20 AC 58 ms
21,672 KB
testcase_21 AC 59 ms
19,544 KB
testcase_22 AC 59 ms
21,756 KB
testcase_23 AC 59 ms
23,780 KB
testcase_24 AC 60 ms
21,576 KB
testcase_25 AC 60 ms
21,580 KB
testcase_26 AC 65 ms
21,644 KB
testcase_27 AC 60 ms
19,684 KB
testcase_28 AC 61 ms
23,760 KB
testcase_29 AC 62 ms
21,816 KB
testcase_30 AC 64 ms
25,744 KB
testcase_31 AC 61 ms
21,776 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace yukicoder349
{
    class Program
    {
        static void Main(string[] args)
        {
            int cnt = int.Parse(Console.ReadLine());

            string[] s = new string[cnt];

            for (int i = 0; i < cnt; i++)
            {
                s[i] = Console.ReadLine();
            }

            if (s.GroupBy(c => c).Select(c => c.Count()).Max() <= ((cnt + 1) / 2))
            {
                Console.WriteLine("YES");
            }
            else
            {
                Console.WriteLine("NO");
            }
        }
    }
}
0