Sereja showed an interesting game to his friends. The game goes like that. Initially, there is a table with an empty cup and n water mugs on it. Then all players take turns to move. During a move, a player takes a non-empty mug of water and pours all water from it into the cup. If the cup overfills, then we assume that this player lost.

As soon as Sereja's friends heard of the game, they wanted to play it. Sereja, on the other hand, wanted to find out whether his friends can play the game in such a way that there are no losers. You are given the volumes of all mugs and the cup. Also, you know that Sereja has (n - 1) friends. Determine if Sereja's friends can play the game so that nobody loses.


-----Input-----

The first line contains integers n and s (2 ≤ n ≤ 100; 1 ≤ s ≤ 1000) — the number of mugs and the volume of the cup. The next line contains n integers a_1, a_2, ..., a_{n} (1 ≤ a_{i} ≤ 10). Number a_{i} means the volume of the i-th mug.


-----Output-----

In a single line, print "YES" (without the quotes) if his friends can play in the described manner, and "NO" (without the quotes) otherwise.


-----Examples-----
Input
3 4
1 1 1

Output
YES

Input
3 4
3 1 3

Output
YES

Input
3 4
4 4 4

Output
NO

Difficulty: interview

Starter code:

Solutions:
n,s=map(int,input().split())
a=list(map(int,input().split()))
a.sort()
if sum(a[:-1])<=s:
    print('YES')
else:
    print('NO')

n,m = list(map(int,input().split()))
a=list(map(int,input().split()))
if sum(a) - max(a) <= m :
    print('YES')
else:
    print('NO')


n, v = list(map(int, input().split()))
a = list(map(int, input().split()))

print('YES' if sum(a) - max(a) <= v else 'NO')


n, s = list(map(int, input().split()))
a = list(map(int, input().split()))
a.remove(max(a))
ans = sum(a) > s
print("NO" if ans else "YES")


n,s = [int(i) for i in input().split()]
l = [int(i) for i in input().split()]
l.sort()
if sum(l[:-1]) <= s:
    print("YES")
else:
    print("NO")


from sys import stdin

n, s = list(map(int, stdin.readline().split()))
arr = list(map(int, stdin.readline().split()))
if(sum(arr) - max(arr) > s):
    print("NO")
else:
    print("YES")

n, s = list(map(int, input().split()))
list_an = list(map(int, input().split()))
if sum(list_an)- max(list_an) <= s:
   print("YES")
else:
   print("NO")


n, m = map(int, input().split())
a = sorted(list(map(int, input().split())))
if sum(a[:-1]) <= m:
    print("YES")
else:
    print("NO")

n, s = map(int, input().split())
a = sorted(map(int, input().split()))
print("NO" if sum(a[:n - 1]) > s else "YES")

__author__ = 'Lipen'

def main():
    n, s = map(int, input().split())
    a = list(map(int, input().split()))

    if sum(a)-max(a) <= s:
        print("YES")
    else:
        print("NO")

main()

n,s=map(int,input().split())
alist=[int(x) for x in input().split()]

alist.sort()

if sum(alist[:(n-1)])<=s:
    print("YES")
else:
    print("NO")

n, s = map(int, input().split())

arr = [int(x) for x in input().split()]

arr.sort()

#print(n, s, arr)

#print(sum(arr[:-1]))

if sum(arr[:-1]) <= s:
    print("YES")
else: print("NO")


n, s = list(map(int, input().split()))
a = [i for i in map(int, input().split())]

r = ["NO", "YES"]
z = sum(a) - max(a) <= s
#print(max(a))
print(r[z])




n,s = list(map(int,input().split()))
a = list(map(int,input().split()))
s_a=sorted(a)
t=0
for i in range(n-1):
	t+=s_a[i]
print('YES' if t<=s else 'NO')



n, s = list(map(int, input().split()))
krush = list(map(int, input().split()))
chasha = 0
res = 'YES'
krush.sort()
friend = 0
while res == 'YES' and friend < len(krush)-1:
    chasha += krush[friend]
    if chasha > s:
        res = 'NO'
    friend += 1
print(res)


n, s = map(int, input().split())
t = list(map(int, input().split()))
t = sorted(t)
if sum(t[:n - 1]) <= s:
    print("YES")
else:
    print("NO")

data = input().rstrip().split()
n = int(data[0])
s = int(data[1])

su = 0
ma = 0
data = input().rstrip().split()
for i in range(n):
    a = int(data[i])
    su += a
    if ma < a:
        ma = a

su -= ma
print('YES' if su <= s else 'NO')


n,s=map(int,input().split())
a=list(map(int,input().split()))
a=sorted(a)
if sum(a[0:n-1])<=s:
    print('YES')
else:
    print('NO')

n, s = [int(i) for i in input().split()]
a = [int(i) for i in input().split()]
result = "NO"

m = max(a)
if sum(a) - m <= s:
    result = "YES"

print(result)


n, s = tuple(map(int, str.split(input())))
if sum(sorted(map(int, str.split(input())))[:-1]) <= s:

    print("YES")

else:

    print("NO")


def readln(): return tuple(map(int, input().split()))

n, s = readln()
a = readln()
print('YES' if sum(a) - max(a) <= s else 'NO')

n, s = map(int, input().split())
a = list(map(int, input().split()))
a = sorted(a)
if sum(a[:-1]) <= s:
    print("YES")
else:
    print("NO")

n,m = map(int,input().split())
a = list(map(int,input().split()))
if sum(a) - max(a) <= m:
    print('YES')
else:
    print('NO')