結果

問題 No.79 過小評価ダメ・ゼッタイ
ユーザー itok217itok217
提出日時 2017-05-28 16:14:03
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 89 ms / 5,000 ms
コード長 574 bytes
コンパイル時間 2,095 ms
コンパイル使用メモリ 102,728 KB
実行使用メモリ 28,372 KB
最終ジャッジ日時 2023-09-08 15:09:27
合計ジャッジ時間 5,102 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 68 ms
23,964 KB
testcase_01 AC 88 ms
28,372 KB
testcase_02 AC 59 ms
19,780 KB
testcase_03 AC 58 ms
21,692 KB
testcase_04 AC 59 ms
21,720 KB
testcase_05 AC 88 ms
28,336 KB
testcase_06 AC 59 ms
19,664 KB
testcase_07 AC 60 ms
21,656 KB
testcase_08 AC 59 ms
21,836 KB
testcase_09 AC 59 ms
23,716 KB
testcase_10 AC 59 ms
21,732 KB
testcase_11 AC 61 ms
21,568 KB
testcase_12 AC 60 ms
21,848 KB
testcase_13 AC 61 ms
21,596 KB
testcase_14 AC 79 ms
22,900 KB
testcase_15 AC 71 ms
20,428 KB
testcase_16 AC 83 ms
25,796 KB
testcase_17 AC 71 ms
22,504 KB
testcase_18 AC 83 ms
23,708 KB
testcase_19 AC 80 ms
24,880 KB
testcase_20 AC 89 ms
26,476 KB
testcase_21 AC 67 ms
21,856 KB
testcase_22 AC 75 ms
24,512 KB
testcase_23 AC 87 ms
28,200 KB
testcase_24 AC 87 ms
24,128 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.Linq;
using System.Collections.Generic;

class Program {
    static void Main() {
        int[] memo = new int[7];
        int n = int.Parse(Console.ReadLine());
        int[] L = Console.ReadLine().Split().Select(int.Parse).ToArray();
        for (int i = 0; i < n; i++) {
            memo[L[i]]++;
        }
        int max = 0;
        int eval = 0;
        for (int i = 1; i <= 6; i++) {
            if (max <= memo[i]) {
                max = memo[i];
                eval = i;
            }
        }
        Console.WriteLine(eval);
    }
}
0