結果

問題 No.1109 調の判定
ユーザー keymoonkeymoon
提出日時 2021-01-15 01:14:21
言語 C#(csc)
(csc 3.9.0)
結果
WA  
実行時間 -
コード長 826 bytes
コンパイル時間 2,424 ms
コンパイル使用メモリ 107,520 KB
実行使用メモリ 19,328 KB
最終ジャッジ日時 2024-05-03 18:00:15
合計ジャッジ時間 4,307 ms
ジャッジサーバーID
(参考情報)
judge4 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 26 ms
19,072 KB
testcase_02 WA -
testcase_03 AC 27 ms
19,200 KB
testcase_04 AC 26 ms
19,200 KB
testcase_05 WA -
testcase_06 WA -
testcase_07 AC 27 ms
19,200 KB
testcase_08 AC 26 ms
19,072 KB
testcase_09 WA -
testcase_10 AC 26 ms
19,200 KB
testcase_11 AC 25 ms
19,200 KB
testcase_12 AC 28 ms
19,200 KB
testcase_13 AC 26 ms
19,200 KB
testcase_14 AC 26 ms
18,944 KB
testcase_15 AC 26 ms
19,200 KB
testcase_16 AC 27 ms
19,328 KB
testcase_17 AC 27 ms
19,072 KB
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 AC 26 ms
19,200 KB
testcase_23 WA -
testcase_24 WA -
testcase_25 AC 25 ms
18,816 KB
testcase_26 AC 25 ms
19,072 KB
testcase_27 AC 27 ms
18,944 KB
testcase_28 WA -
testcase_29 AC 26 ms
19,200 KB
testcase_30 AC 25 ms
19,072 KB
testcase_31 WA -
testcase_32 WA -
testcase_33 WA -
testcase_34 WA -
testcase_35 AC 26 ms
19,072 KB
testcase_36 AC 27 ms
19,072 KB
testcase_37 AC 27 ms
18,944 KB
testcase_38 AC 26 ms
18,944 KB
testcase_39 AC 27 ms
19,072 KB
testcase_40 AC 25 ms
19,200 KB
testcase_41 AC 27 ms
19,200 KB
testcase_42 WA -
testcase_43 AC 27 ms
19,072 KB
testcase_44 AC 28 ms
19,328 KB
testcase_45 AC 27 ms
19,072 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;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Numerics;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using static System.Math;
public static class P
{
    public static void Main()
    {
        int n = int.Parse(Console.ReadLine());
        var t = Console.ReadLine().Split().Select(int.Parse).ToArray();
        var d = new[] { 0, 2, 4, 5, 7, 9, 11 };
        int res = -1;
        for (int i = 0; i < n; i++)
        {
            if (t.Except(d.Select(x => (x + i) % 12)).Any()) continue;
            if (res != -1)
            {
                Console.WriteLine(-1);
                return;
            }
            res = i;
        }
        Console.WriteLine(res);
    }
}
0