For a given array $a$ consisting of $n$ integers and a given integer $m$ find if it is possible to reorder elements of the array $a$ in such a way that $\sum_{i=1}^{n}{\sum_{j=i}^{n}{\frac{a_j}{j}}}$ equals $m$? It is forbidden to delete elements as well as insert new elements. Please note that no rounding occurs during division, for example, $\frac{5}{2}=2.5$.


-----Input-----

The first line contains a single integer $t$ — the number of test cases ($1 \le t \le 100$). The test cases follow, each in two lines.

The first line of a test case contains two integers $n$ and $m$ ($1 \le n \le 100$, $0 \le m \le 10^6$). The second line contains integers $a_1, a_2, \ldots, a_n$ ($0 \le a_i \le 10^6$) — the elements of the array.


-----Output-----

For each test case print "YES", if it is possible to reorder the elements of the array in such a way that the given formula gives the given value, and "NO" otherwise.


-----Example-----
Input
2
3 8
2 5 1
4 4
0 1 2 3

Output
YES
NO



-----Note-----

In the first test case one of the reorders could be $[1, 2, 5]$. The sum is equal to $(\frac{1}{1} + \frac{2}{2} + \frac{5}{3}) + (\frac{2}{2} + \frac{5}{3}) + (\frac{5}{3}) = 8$. The brackets denote the inner sum $\sum_{j=i}^{n}{\frac{a_j}{j}}$, while the summation of brackets corresponds to the sum over $i$.

Difficulty: interview

Starter code:

Solutions:
import sys
input=sys.stdin.readline

T=int(input())
for _ in range(T):
    n,m=list(map(int,input().split()))
    A=list(map(int,input().split()))
    s=sum(A)
    if (s==m):
        print("YES")
    else:
        print("NO")


for _ in range(int(input())):
    n,m = map(int,input().split())
    List = [int(x) for x in input().split()]
    if(sum(List) == m):
        print("YES")
    else:
        print("NO")

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


from sys import stdin, stdout
input = stdin.readline
from collections import defaultdict as dd
import math
def geti(): return list(map(int, input().strip().split()))
def getl(): return list(map(int, input().strip().split()))
def gets(): return input()
def geta(): return int(input())
def print_s(s): stdout.write(s+'\n')

def solve():
    for _ in range(geta()):
        n,m=geti()
        a=getl()
        if sum(a)==m:
            print("YES")
        else:
            print("NO")


def __starting_point():
    solve()

__starting_point()

import sys
input = sys.stdin.readline
for f in range(int(input())):
    n,m=map(int,input().split())
    a=list(map(int,input().split()))
    if sum(a)==m:
        print("YES")
    else:
        print("NO")

#   ==========     //\\       //||     ||====//||
#       ||        //  \\        ||     ||   // ||
#       ||       //====\\       ||     ||  //  ||
#       ||      //      \\      ||     || //   ||
#   ========== //        \\  ========  ||//====|| 
#  code

def solve():
    n, m = map(int, input().split())
    a = list(map(int, input().split()))

    if sum(a) == m:
        print('YES')
    else:
        print('NO')



def main():
    t = 1
    t = int(input())
    for _ in range(t):
        solve()

def __starting_point():
    main()
__starting_point()

import sys

input = sys.stdin.readline

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


for t in range(int(input())):
    n, m = list(map(int, input().split()))
    nums = list(map(int, input().split()))
    if sum(nums) ==m:
        print("YES")
    else:
        print("NO")


a=int(input())
for i in range(a):
    x,y=list(map(int,input().split()))
    z=list(map(int,input().split()))
    if(sum(z)==y):
        print('YES')
    else:
        print('NO')
        


from sys import stdin, stdout
t=int(stdin.readline())
for i in range(t):
	n,m=list(map(int,stdin.readline().split()))
	arr=list(map(int,stdin.readline().split()))
	if sum(arr)==m:
		print('YES')
	else:
		print('NO')


# map(int, input().split())
def main():
    n, m = map(int, input().split())
    a = list(map(int, input().split()))
    if sum(a) == m:
        print('YES')
    else:
        print('NO')


rw = int(input())
for wewq in range(rw):
    main()

# Anything is possible when you are inner peace. Master Shifu (Kung Fun Panda)
# by : Blue Edge - Create some chaos

for _ in range(int(input())):
    n,m=list(map(int,input().split()))
    a=list(map(int,input().split()))
    print(["YES","NO"][sum(a)!=m])


import sys
import re
import random
import math
import copy
from heapq import heappush, heappop, heapify
from functools import cmp_to_key
from bisect import bisect_left, bisect_right
from collections import defaultdict, deque, Counter
# sys.setrecursionlimit(1000000)

# input aliases
input = sys.stdin.readline
getS = lambda: input().strip()
getN = lambda: int(input())
getList = lambda: list(map(int, input().split()))
getZList = lambda: [int(x) - 1 for x in input().split()]

INF = float("inf")
MOD = 10**9 + 7
divide = lambda x: pow(x, MOD-2, MOD)


def calc(arr, idx):
    ret = 0
    for i in range(len(arr)):
        if idx == 0:
            break
        if idx & 1:
            ret += arr[i]
        idx >>= 1

    return ret

def get_all_comb(arr):
    n = len(arr)
    ret = []
    for idx in range(1 << n):
        ret.append(calc(arr, idx))

    return ret

def solve():
    n, m =getList()
    li = getList()

    if sum(li) == m:
        print("YES")
    else:
        print("NO")
    return
def main():
    n = getN()
    for _ in range(n):
        solve()

    return
def __starting_point():
    main()
    # solve()

__starting_point()

t = int(input())
for _ in range(t):
	n, m = map(int, input().split())
	arr = [int(j) for j in input().split()]
	if sum(arr) == m:
		print("YES")
	else:
		print("NO")

def __starting_point():
    t = int(input())
    while t:
        t -= 1
        n, m = map(int, input().split())
        a = [int(x) for x in input().split()]
        sum = 0
        for i in a:
            sum += i
        if sum == m:
            print('YES')
        else:
            print('NO')
__starting_point()

def solve():
    n, m = list(map(int, input().split()))
    a = list(map(int, input().split()))
    if sum(a) == m:
        print("YES")
    else:
        print("NO")
    return


def main():
    t = int(input())
    for i in range(t):
        solve()
    return


def __starting_point():
    main()


__starting_point()

for t in range(int(input())):
	n,m=[int(x) for x in input().split(' ')]
	a=[int(x) for x in input().split(' ')]
	ss=sum(a)
	if(ss==m):
		print("YES")
	else:
		print("NO")

def solve(n,m):
    s=list(map(int,input().split()))
    if sum(s)==m :
        return 'YES'
    return 'NO'

for _ in range(int(input())):
    n,m=list(map(int,input().split()))
    print(solve(n,m))



ans = []
for _ in range(int(input())):
    n, m = map(int, input().split())
    u = list(map(int, input().split()))
    if sum(u) == m:
        ans.append('YES')
    else:
        ans.append('NO')
print(*ans, sep='\n')


for _ in range(int(input())):
    n,m=list(map(int,(input().split())))
    arr=list(map(int,input().split()))
    if sum(arr)==m:
        print("YES")
    else:
        print("NO")


import sys
import math
import itertools
import functools
import collections
import operator
import fileinput
import copy
import string


ORDA = 97  # a
def ii(): return int(input())
def mi(): return map(int, input().split())
def li(): return [int(i) for i in input().split()]
def lcm(a, b): return abs(a * b) // math.gcd(a, b)
def revn(n): return str(n)[::-1]
def dd(): return collections.defaultdict(int)
def ddl(): return collections.defaultdict(list)
def sieve(n):
    if n < 2: return list()
    prime = [True for _ in range(n + 1)]
    p = 3
    while p * p <= n:
        if prime[p]:
            for i in range(p * 2, n + 1, p):
                prime[i] = False
        p += 2
    r = [2]
    for p in range(3, n + 1, 2):
        if prime[p]:
            r.append(p)
    return r
def divs(n, start=2):
    r = []
    for i in range(start, int(math.sqrt(n) + 1)):
        if (n % i == 0):
            if (n / i == i):
                r.append(i)
            else:
                r.extend([i, n // i])
    return r
def divn(n, primes):
    divs_number = 1
    for i in primes:
        if n == 1:
            return divs_number
        t = 1
        while n % i == 0:
            t += 1
            n //= i
        divs_number *= t
def prime(n):
    if n == 2: return True
    if n % 2 == 0 or n <= 1: return False
    sqr = int(math.sqrt(n)) + 1
    for d in range(3, sqr, 2):
        if n % d == 0: return False
    return True
def convn(number, base):
    new_number = 0
    while number > 0:
        new_number += number % base
        number //= base
    return new_number
def cdiv(n, k): return n // k + (n % k != 0)
def ispal(s):
    for i in range(len(s) // 2 + 1):
        if s[i] != s[-i - 1]:
            return False
    return True


for _ in range(ii()):
    n, m = mi()
    a = li()
    if sum(a) == m:
        print("YES")
    else:
        print('NO')

for u in range(int(input())):
    n, m = map(int, input().split())
    x = [int(w) for w in input().split()]
    
    if(sum(x) == m):
        print("YES")
        
    else:
        print("NO")

t = int(input())
for _ in range(t):
    n,m = map(int, input().split())
    l=list(map(int, input().split()))
    if sum(l)==m:
        print('YES')
    else:
        print('NO')

t=int(input())
for i in range(t):
    n,m=list(map(int,input().split()))
    b=list(map(int,input().split()))
    if sum(b)==m:
        print("YES")
    else:
        print("NO")


t = int(input())

for i in range(t):
    n, m = list(map(int, input().split()))
    a = list(map(int, input().split()))

    summ = 0
    for i in range(n):
        summ += a[i]

    if summ == m:
        print('YES')
    else:
        print('NO')