t=int(input()) for _ in range(t): n=int(input()) a=list(map(int,input().split())) if(sum(a)%n==n//2): print("YES") else: print("NO")