結果

問題 No.2016 Countdown Divisors
ユーザー 👑 kakel-sankakel-san
提出日時 2022-07-22 21:38:41
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 106 ms / 2,000 ms
コード長 779 bytes
コンパイル時間 842 ms
コンパイル使用メモリ 67,812 KB
実行使用メモリ 27,588 KB
最終ジャッジ日時 2023-09-17 09:14:15
合計ジャッジ時間 4,069 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 57 ms
22,648 KB
testcase_01 AC 106 ms
27,588 KB
testcase_02 AC 106 ms
25,452 KB
testcase_03 AC 100 ms
25,572 KB
testcase_04 AC 95 ms
27,396 KB
testcase_05 AC 93 ms
25,256 KB
testcase_06 AC 70 ms
22,604 KB
testcase_07 AC 70 ms
20,640 KB
testcase_08 AC 104 ms
27,532 KB
testcase_09 AC 104 ms
27,428 KB
testcase_10 AC 103 ms
25,532 KB
testcase_11 AC 105 ms
27,420 KB
testcase_12 AC 104 ms
27,520 KB
testcase_13 AC 96 ms
25,544 KB
testcase_14 AC 95 ms
27,500 KB
testcase_15 AC 94 ms
25,344 KB
testcase_16 AC 102 ms
27,564 KB
testcase_17 AC 98 ms
25,400 KB
testcase_18 AC 100 ms
25,460 KB
testcase_19 AC 56 ms
20,660 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

using System;
using static System.Console;
using System.Linq;
using System.Collections.Generic;

class Program
{
    static int NN => int.Parse(ReadLine());
    static int[] NList => ReadLine().Split().Select(int.Parse).ToArray();
    static void Main()
    {
        var t = NN;
        var res = new int[t];
        for (var u = 0; u < t; ++u)
        {
            var n = NN;
            res[u] = CountDown(n);
        }
        WriteLine(string.Join("\n", res));
    }
    static int CountDown(int n)
    {
        switch(n)
        {
            case 1:
            case 3:
            case 4:
            case 5:
            case 7:
            case 8:
            return 1;
            default:
            return 2;
        }
    }
}
0