結果
| 問題 |
No.1823 Tricolor Dango
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-05-09 02:03:10 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 103 ms / 2,000 ms |
| コード長 | 433 bytes |
| コンパイル時間 | 213 ms |
| コンパイル使用メモリ | 82,168 KB |
| 実行使用メモリ | 100,152 KB |
| 最終ジャッジ日時 | 2024-07-16 03:09:08 |
| 合計ジャッジ時間 | 4,098 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 25 |
ソースコード
#!/usr/bin/env python3
import sys
MOD = 998244353
input = sys.stdin.readline
def main():
T = int(input())
for _ in range(T):
N = int(input())
A = list(map(int, input().split()))
S = sum(A)
if S % 3 != 0:
print("No")
continue
if max(A) > S // 3:
print("No")
continue
print("Yes")
return
if __name__ == '__main__':
main()