結果

問題 No.1823 Tricolor Dango
ユーザー hiragnhiragn
提出日時 2022-11-25 01:01:41
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 133 ms / 2,000 ms
コード長 283 bytes
コンパイル時間 95 ms
コンパイル使用メモリ 11,776 KB
実行使用メモリ 31,932 KB
最終ジャッジ日時 2024-04-08 22:05:34
合計ジャッジ時間 4,335 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 34 ms
9,856 KB
testcase_01 AC 133 ms
9,856 KB
testcase_02 AC 131 ms
9,856 KB
testcase_03 AC 133 ms
9,856 KB
testcase_04 AC 62 ms
9,984 KB
testcase_05 AC 61 ms
9,984 KB
testcase_06 AC 60 ms
9,984 KB
testcase_07 AC 52 ms
10,368 KB
testcase_08 AC 50 ms
10,368 KB
testcase_09 AC 54 ms
10,368 KB
testcase_10 AC 52 ms
10,368 KB
testcase_11 AC 53 ms
10,368 KB
testcase_12 AC 49 ms
10,368 KB
testcase_13 AC 56 ms
12,688 KB
testcase_14 AC 54 ms
12,812 KB
testcase_15 AC 51 ms
12,772 KB
testcase_16 AC 42 ms
14,460 KB
testcase_17 AC 42 ms
14,020 KB
testcase_18 AC 60 ms
20,560 KB
testcase_19 AC 98 ms
31,932 KB
testcase_20 AC 59 ms
20,368 KB
testcase_21 AC 93 ms
9,856 KB
testcase_22 AC 127 ms
9,856 KB
testcase_23 AC 68 ms
9,984 KB
testcase_24 AC 91 ms
9,856 KB
testcase_25 AC 126 ms
9,856 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

def main():
    t = int(input())

    for _ in range(t):
        _ = int(input())
        a = list(map(int, input().split()))
        if sum(a) % 3 == 0 and max(a) <= sum(a) // 3:
            print('Yes')
        else:
            print('No')


if __name__ == "__main__":
    main()
0