結果

問題 No.1823 Tricolor Dango
ユーザー irumo8202irumo8202
提出日時 2022-01-28 22:05:35
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 191 ms / 2,000 ms
コード長 306 bytes
コンパイル時間 238 ms
コンパイル使用メモリ 86,992 KB
実行使用メモリ 100,424 KB
最終ジャッジ日時 2023-08-28 20:03:18
合計ジャッジ時間 4,604 ms
ジャッジサーバーID
(参考情報)
judge13 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 70 ms
71,212 KB
testcase_01 AC 187 ms
78,988 KB
testcase_02 AC 185 ms
78,044 KB
testcase_03 AC 191 ms
78,064 KB
testcase_04 AC 127 ms
77,640 KB
testcase_05 AC 128 ms
77,688 KB
testcase_06 AC 126 ms
77,668 KB
testcase_07 AC 84 ms
76,824 KB
testcase_08 AC 86 ms
76,536 KB
testcase_09 AC 85 ms
76,924 KB
testcase_10 AC 84 ms
76,696 KB
testcase_11 AC 85 ms
76,788 KB
testcase_12 AC 84 ms
76,784 KB
testcase_13 AC 83 ms
77,724 KB
testcase_14 AC 83 ms
77,644 KB
testcase_15 AC 81 ms
77,384 KB
testcase_16 AC 78 ms
80,792 KB
testcase_17 AC 79 ms
80,728 KB
testcase_18 AC 86 ms
88,384 KB
testcase_19 AC 121 ms
100,424 KB
testcase_20 AC 87 ms
88,508 KB
testcase_21 AC 164 ms
78,248 KB
testcase_22 AC 179 ms
78,304 KB
testcase_23 AC 149 ms
79,380 KB
testcase_24 AC 161 ms
78,192 KB
testcase_25 AC 184 ms
78,248 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

def solve():
    N = int(input())
    A = list(map(int, input().split()))

    sumA = sum(A)
    x = sumA / 3
    flg = True
    if x != int(x):
        flg = False
    for a in A:
        if a > x:
            flg = False
    print("Yes" if flg else "No")


T = int(input())
for _ in range(T):
    solve()
0