Problem:
 Score : 200 points    Problem Statement Determine if an N -sided polygon (not necessarily convex) with sides of length L_1, L_2, ..., L_N can be drawn in a two-dimensional plane.  You can use the following theorem:  Theorem : an N -sided polygon satisfying the condition can be drawn if and only if the longest side is strictly shorter than the sum of the lengths of the other N-1 sides.      Constraints  All values in input are integers.  3 \leq N \leq 10  1 \leq L_i \leq 100         Input Input is given from Standard Input in the following format:  N  L_1  L_2  ...  L_N       Output If an N -sided polygon satisfying the condition can be drawn, print Yes ; otherwise, print No .        Sample Input 1 4
3 8 5 1      Sample Output 1 Yes  Since 8 < 9 = 3 + 5 + 1 , it follows from the theorem that such a polygon can be drawn on a plane.       Sample Input 2 4
3 8 4 1      Sample Output 2 No  Since 8 \geq 8 = 3 + 4 + 1 , it follows from the theorem that such a polygon cannot be drawn on a plane.       Sample Input 3 10
1 8 10 5 8 12 34 100 11 3      Sample Output 3 No

Solution (Python):
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**7)
from collections import Counter, deque
from collections import defaultdict
from itertools import combinations, permutations, accumulate, groupby, product
from bisect import bisect_left,bisect_right
from heapq import heapify, heappop, heappush
from math import floor, ceil
from operator import itemgetter
from copy import deepcopy
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def LI2(): return [int(input()) for i in range(n)]
def MXI(): return [[LI()]for i in range(n)]
inf = 10**17
mod = 10**9 + 7


n=I()
l=sorted(LI(),reverse=True)
if sum(l)>2*l[0]:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
l = list(map(int, input().split()))
l.sort(reverse=True)
if l[0] < sum(l[1:]):
    print('Yes')
else:
    print('No')

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
l.sort()
if sum(l[0:n-1])>l[n-1]:
  print("Yes")
else:
  print("No")

Solution (Python):
s = int(input())
n = list(map(int,(input().split())))
n = sorted(n)
if n[-1] < sum(n)-n[-1]:
  print("Yes")
else:
  print("No")

Solution (Python):

n = int(input()) 
l = sorted(list(map(int, input().split())))
print("Yes") if l[-1] < sum(l[:-1]) else print("No")

Solution (Python):
n=int(input())
l = [int(_) for _ in input().split()]
print('Yes' if max(l)<sum(l)-max(l) else 'No')

Solution (Python):
n=int(input())
l=sorted(list(map(int,input().split())))
if l[-1]<sum(l[:n-1]):
    print('Yes')
else:
    print('No')

Solution (Python):
N = int(input())
List = list(map(int,input().split()))
if max(List) < sum(List)-max(List):
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
L = list(map(int,input().split()))
print('Yes' if sum(L)-2*max(L) > 0 else 'No')

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
a=max(l)
l.remove(a)
if a<sum(l):
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
l = list(map(int,input().split()))
sum_l = sum(l)
print('Yes' if all([sum_l-i > i for i in l]) else 'No')

Solution (Python):
n = int(input())
l = [int(i) for i in input().split()]
if 2*max(l) < sum(l):
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
l = list(map(int,input().split()))

l.sort(reverse=True)
ans =0
for i in range(1,n):
    ans+=l[i]

if ans > l[0]:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
L = list(map(int, input().split()))
idx = L.index(max(L))
sum_L = 0
for i in range(len(L)):
    if i == idx:
        pass
    else:
        sum_L += L[i]

if L[idx] < sum_L:
    print('Yes')
else:
    print('No')

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
max_= max(l)
if sum(l)>2*max_:
	print('Yes')
else:
	print('No')

Solution (Python):
input()
A = list(map(int,input().split()))
print('Yes' if max(A) < sum(A)/2 else 'No')

Solution (Python):
n = int(input())
l = list(map(int, input().split()))
if max(l) < sum(l)-max(l):
    print("Yes")
else:
    print("No")

Solution (Python):

n = int(input())
l = list(map(int,input().split()))
l.sort()
l_max = l[-1]
ans = 1
s = sum(l) - l_max
if s > l_max:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
a = sorted(list(map(int, input().split())))
if sum(a) > 2 * a[-1]:
  print('Yes')
else:
  print('No')

Solution (Python):
N = int(input())
l = list(map(int, input().split()))

num = l.pop(l.index(max(l)))
if num < sum(l):
    print('Yes')
else:
    print('No')

Solution (Python):
N = input()
data = list(map(int, input().split()))

max = max(data)

sum = sum(data)

flag = sum - max
if (max < flag):
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
l = map(int, input().split())
l = sorted(l)
if l[-1] < sum(l[:-1]):
    print('Yes')
else:
    print('No')

Solution (Python):

def inputlist(): return [int(k) for k in input().split()]

N = int(input())
L = inputlist()
L.sort()
s=sum(L)
s -=L[-1]
if L[-1] < s:
    print("Yes")
else:
    print("No")

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
l.sort()
l.reverse()
max=l[0]
sum=0
for i in range(1,n):
    sum+=l[i]
if max<sum:
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
li = input().split()
lis = [int(x) for x in li ]
a = sum(lis)
m = max(lis)
a -=m
if m < a:
	print('Yes')
else:
	print('No')

Solution (Python):
n = int(input())
arr = list(map(int,input().split()))
arr.sort()
longest = arr[-1]
sonota = sum(arr)-longest
if longest<sonota:
  print('Yes')
else:
  print('No')

Solution (Python):


def solve():

    N = int(input())
    Llist = list(map(int, input().split()))

    MAX = max(Llist)

    if MAX < sum(Llist)-MAX:
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    solve()

Solution (Python):
n = int(input())
sides = [int(x) for x in input().split()]
tot = sum(sides)

for i in sides:
  if tot - i <= i:
    print('No')
    break
else:
  print('Yes')

Solution (Python):
n = int(input())
l = sorted(list(map(int,input().split())),reverse = True)
if sum(l[1:]) > l[0]:
    print('Yes')
else:
    print('No')

Solution (Python):
N=int(input())
L=list(map(int,input().split()))
L=sorted(L)
if sum(L[:-1])>L[-1]:
  print('Yes')
else:
  print('No')

Solution (Python):
n = int(input())
l = list(map(int, input().split()))

for i in range(len(l)):
    if l[i] >= sum(l[:i]) + sum(l[i+1:]):
        print('No')
        exit()

print('Yes')

Solution (Python):
N = int(input())
L = sorted(list(map(int, input().split())))
if L[-1] < sum(L[:-1]):
    print('Yes')
else:
    print('No')

Solution (Python):
N = int(input())
L = [int(i) for i in input().split()]
print('Yes' if sum(L) > 2 * max(L) else 'No')

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
L = LIST()

MAX = max(L)
SUM = sum(L)

if MAX < SUM-MAX :
	print("Yes")
else:
	print("No")

Solution (Python):
inf = 10**9+7
mod = 10**9+7
n = int(input())
a = list(map(int, input().split()))
maxa = max(a)
a.remove(maxa)
if maxa < sum(a):
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
l = list(map(int,input().split()))

for i in l:
    if i < sum(l)-i:
        pass
    else:
        print ("No")
        exit ()
print ("Yes")

Solution (Python):
def Polygon(n, ll):

    return "Yes" if max(ll) < sum(ll)-max(ll) else "No"

def main():
    n = int(input())
    ll = list(map(int, input().split()))
    print(Polygon(n, ll))

if __name__ == '__main__':
    main()

Solution (Python):

import sys

sr = lambda: sys.stdin.readline().rstrip()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

N = ir()
L = lr(); L.sort()
bl = L[-1] < sum(L[:-1])
print('Yes' if bl else 'No')

Solution (Python):
def main():
    import sys
    input = sys.stdin.readline
    sys.setrecursionlimit(10**7)
    from collections import Counter, deque
    
    from itertools import combinations, permutations, accumulate, groupby, product
    from bisect import bisect_left,bisect_right
    from heapq import heapify, heappop, heappush
    from math import floor, ceil
    

    
    

    n = int(input())
    l = list(map(int, input().split()))
    if max(l) < sum(l)-max(l):
        print('Yes')
    else:
        print('No')

if __name__ == '__main__':
    main()

Solution (Python):

n = int(input())
l = list(map(int,input().split()))
l.sort()

if (sum(l)-l[-1]) > l[-1]:
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
L = list(map(int, input().split()))

max_L = max(L)
sum_excluded_max_L = sum(L) - max_L

answer = 'Yes' if max_L < sum_excluded_max_L else 'No'

print(answer)

Solution (Python):
import sys
readline = sys.stdin.readline

def main():
    N = int(input())
    L = list(map(int, readline().rstrip().split()))
    if max(L) < sum(L) - max(L):
        print('Yes')
    else:
        print('No')


if __name__ == '__main__':
    main()

Solution (Python):
N = int(input())
L = list(map(int,input().split()))
L.sort()
if sum(L)>2*L[N-1]:
    print("Yes")
else:
    print("No")

Solution (Python):
def main():
    N = int(input())
    *a, = map(int, input().split())

    ma = max(a)
    s = sum(a)
    cond = ma - (s - ma) < 0
    print('Yes' if cond else 'No')


if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())
l = list(map(int, input().split()))
sort_l = sorted(l)
sum_n_1 = sum(sort_l[:len(sort_l)-1])
longest = sort_l[len(sort_l)-1]
if longest < sum_n_1:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
li = list(map(int,input().split()))

li.sort()

if sum(li[:-1]) > li[-1]:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
l = list(map(int, input().split()))
l.sort()
if sum(l) > 2 * l[n - 1]:
    print("Yes")
else:
    print("No")

Solution (Python):
import sys, re, os
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from heapq import heapify, heappop, heappush

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def S_MAP(): return map(str, input().split())
def LIST(): return list(map(int, input().split()))
def S_LIST(): return list(map(str, input().split()))
 
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
L = LIST()

l = sorted(L)
if l[-1] < sum(l[:-1]):
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
l = list(map(int,input().split()))
if sum(l) - max(l) > max(l):
    print('Yes')
else:
    print('No')

Solution (Python):



N = int(input())
l_nums = list(map(int, input().split()))


is_ok = True


for i in range(N):
    check_sum = 0
    for j in range(N):
        if i==j:
            continue
        check_sum += l_nums[j]
    if l_nums[i]>=check_sum:
        is_ok = False


if is_ok:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
al = list(map(int, input().split()))
if max(al) < sum(al)-max(al):
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
ll = list(map(int,input().split()))

ll = sorted(ll, reverse=True)

if sum(ll[1:]) > ll[0]:
    print("Yes")
else:
    print("No")

Solution (Python):

from collections import defaultdict, deque
from heapq import heappush, heappop
from itertools import permutations, accumulate
import sys
import math
import bisect
def LI(): return [int(x) for x in sys.stdin.buffer.readline().split()]
def I(): return int(sys.stdin.buffer.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res
def IR(n):
    return [I() for i in range(n)]
def LIR(n):
    return [LI() for i in range(n)]
def SR(n):
    return [S() for i in range(n)]
def LSR(n):
    return [LS() for i in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007

def solve():
    n = I()
    l = LI()
    s = sum(l)
    m = max(l)
    if 2*m < s:
        print("Yes")
    else:
        print("No")
    return


if __name__ == "__main__":
    solve()

Solution (Python):
n=int(input())
l=list(map(int,input().split()))

if max(l)*2 >=sum(l):
  print("No")
  exit()
print("Yes")

Solution (Python):
N = int(input())
L = [int(i) for i in input().split()]
L.sort()

flag = True if sum(L[:-1]) > L[-1] else False

if flag:
    print('Yes')
else:
    print('No')

Solution (Python):
N = int(input())
L = list(map(int, input().split()))

L.sort()

if L[-1] < sum(L[:-1]):
    print("Yes")

else:
    print("No")

Solution (Python):
n = int(input())
l = list(map(int,input().split()))
x = max(l)
if sum(l)-x>x:
    print('Yes')
else:
    print('No')

Solution (Python):
import sys, re, os
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from heapq import heapify, heappop, heappush

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def S_MAP(): return map(str, input().split())
def LIST(): return list(map(int, input().split()))
def S_LIST(): return list(map(str, input().split()))
 
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
L = LIST()

l = sorted(L)
if l[-1] < sum(l[:-1]):
    print("Yes")
else:
    print("No")

Solution (Python):
def resolve():
  n = int(input())
  l = list(map(int, input().split()))
  l.sort()
  sum = 0
  for i in range(n-1):
    sum += l[i]

  if sum > l[n-1]:
    print("Yes")
  else:
    print("No")
  return

if __name__ == "__main__":
  resolve()

Solution (Python):
N = int(input())
L = list(map(int, input().split()))

if max(L)*2 < sum(L):
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
l = list(map(int,input().split()))
l.sort()
ml = l[-1]
s = sum(l[:n-1])
if ml < s:print('Yes')
else:print('No')

Solution (Python):
N = int(input())
Ln = list(map(int,input().split(' ')))
max_num = 0
sum_num = 0
for l in Ln:
    sum_num += l
    max_num = max(max_num,l)
if sum_num - max_num > max_num:
    print('Yes')
else:
    print('No')

Solution (Python):
N = int(input())
L = list(map(int,input().split()))
tot = sum(L)
lmax = max(L)
tot -= lmax
if tot>lmax:
    print("Yes")
else:
    print("No")

Solution (Python):
n=int(input())
L=list(map(int,input().split()))
L.sort()
print("Yes" if sum(L[:-1]) > L[-1]  else "No")

Solution (Python):
from heapq import heappush, heappop
from itertools import permutations, accumulate, combinations
import math
import bisect
import numpy as np
from collections import defaultdict, deque
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 6)




def main():
    n = int(input())
    l = list(map(int, input().split()))
    m = max(l)
    s = sum(l) - m
    if m < s:
        print("Yes")
    else:
        print("No")
if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())
l = list(map(int, input().split()))
l.sort()
s = 0
for i in range(n-1):
    s += l[i]
if s > l[-1]:
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
L = list(map(int,input().split()))
l = sorted(L)
c = sum(l)-l[len(L)-1] 
if l[len(L)-1] < c:
  print('Yes')
else:
  print('No')

Solution (Python):
def resolve():
    n = int(input())
    l = list(map(int, input().split()))
    l = sorted(l)
    maxl = l[-1]
    if sum(l[:len(l)-1]) >maxl:
        print("Yes")
    else:
        print("No")
resolve()

Solution (Python):
N = int(input())
L = list(map(int, input().split()))

if max(L) < sum(L) - max(L):
    print("Yes")
else:
    print("No")

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
l.sort()
lmax=l[-1]
lsum=sum(l[:n-1])
if lmax<lsum:print("Yes")
else:print("No")

Solution (Python):
N = int(input())
L = sorted(list(map(int, input().split())))
if L[-1] < sum(L[:-1]):
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

M = max(A)
if M < sum(A)-M:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
l = list(map(int,input().split()))
if max(l)< sum(l)-max(l):
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
L = list(map(int, input().split()))

if max(L) < sum(L)-max(L):
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
L = list(map(int, input().split()))

L.sort()
print("Yes" if sum(L[:-1]) > L[-1] else "No")

Solution (Python):
def main():
    n = int(input())
    l = [int(x) for x in input().split()]
    all_l = sum(l)
    l.sort()
    print("Yes" if all(l[-1] < all_l - l[-1] for i in range(n)) else "No")


if __name__ == '__main__':
    main()

Solution (Python):
def examA():
    N = I()
    L = LI()
    L.sort()
    if sum(L)<=L[-1]*2:
        print("No")
    else:
        print("Yes")
    return

def examB():
    ans = 0
    print(ans)
    return

def examC():
    ans = 0
    print(ans)
    return

def examD():
    ans = 0
    print(ans)
    return

def examE():
    ans = 0
    print(ans)
    return

def examF():
    ans = 0
    print(ans)
    return

import sys,bisect,itertools,heapq,math,random
from copy import deepcopy
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict,deque
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
def I(): return int(readline())
def LI(): return list(map(int,readline().split()))
def LSI(): return list(map(str,sys.stdin.readline().split()))
def LS(): return sys.stdin.readline().split()
def SI(): return sys.stdin.readline().strip()
global mod,mod2,inf,alphabet,_ep
mod = 10**9 + 7
mod2 = 998244353
inf = 10**18
_ep = 10**(-12)
alphabet = [chr(ord('a') + i) for i in range(26)]

sys.setrecursionlimit(10**7)

if __name__ == '__main__':
    examA()

"""
142
12 9 1445 0 1
asd dfg hj o o
aidn
"""

Solution (Python):
icase=0
if icase==0:
    n=int(input())
    l=list(map(int,input().split()))
    lmax=max(l)
    r=sum(l)-lmax
    if r>lmax:
        print("Yes")
    else:
        print("No")

Solution (Python):
def main():
    N = int(input())
    L = [int(a) for a in input().split()]
    lmax = max(L)
    L.remove(lmax)
    if sum(L) > lmax :
        print("Yes")
    else:
        print("No")
main()

Solution (Python):
n=int(input())
A=sorted(map(int,input().split()))
if A[n-1]<sum(A)-A[n-1]:
    print("Yes")
else:
    print("No")

Solution (Python):
a = input()
l = list(map(int, input().split()))
if 2 * max(l)< sum(l):
  print('Yes')
else:
  print('No')

Solution (Python):
N = int(input())
L = list(map(int, input().split()))
ans = 'Yes' if 2 * max(L) < sum(L) else 'No'
print(ans)

Solution (Python):
N=int(input())
L=list(map(int,input().split()))
A=sorted(L)
if A[-1]<(sum(A))-A[-1]:
    print("Yes")
else:
    print("No")

Solution (Python):

N = int(input())
L = [int(s) for s in input().split()]

print('Yes' if max(L) < sum(L) - max(L)  else 'No')

Solution (Python):
n=int(input())
l=list(map(int,input().split()))

if max(l)<sum(l)-max(l):
  print('Yes')
else:
  print('No')

Solution (Python):


data = int(input())
array = list(map(int, input().split()))
one=max(array)
two=sum(array)-one
print("Yes" if two>one else "No")

Solution (Python):
import numpy as np
N= int(input())
L=[int(x) for x in input().split()]

L_max=np.max(L)
L_sum=sum(L)-L_max

if L_sum > L_max:
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
l = max(a)
s = sum(a)
if s-2*l > 0:
  print('Yes')
else:
  print('No')

Solution (Python):
import numpy as np

N = int(input())
L = input().split()
L = [int(l) for l in L]

ind = np.argmax(L)
maxL = L.pop(ind)

if maxL < sum(L):
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
l = list(map(int, input().split()))
ma = max(l)
l.remove(ma)
lsu = sum(l)

if lsu>ma:
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
L = [int(x) for x in input().split()]
if sum(L) - max(L) > max(L):
    print('Yes')
else:
    print('No')

Solution (Python):
N = int(input())
L = list(map(int,input().split()))
if max(L) * 2 < sum(L):
    print("Yes")
else:
    print("No")

Solution (Python):

 
cmdvar_N=int(input())
cmdvar_numlist=input()
cmdvar_numlist_splited=[int(s) for s in cmdvar_numlist.split()]
sum=0

if cmdvar_N != len(cmdvar_numlist_splited):
    print("error")
    exit(-1)

cmdvar_numlist_splited.sort(reverse=True)

top_max_number=cmdvar_numlist_splited[0]

for List in cmdvar_numlist_splited:
    sum=int(sum)+int(List)

if int(top_max_number) < sum-int(top_max_number):
    print("Yes")
else:
    print("No")

Solution (Python):
n=int(input())
l=sorted(list(map(int,input().split())))
print("Yes" if l[-1]<sum(l[:-1]) else "No")

Solution (Python):
n=input()
l=list(map(int,input().split()))
print("Yes" if 2*max(l)<sum(l) else "No")

Solution (Python):
n=input()
l=list(map(int,input().split()))
print("Yes" if max(l)<sum(l)-max(l) else "No")

Solution (Python):
N=int(input())
L=[int(i) for i in input().split()]
if max(L)<(sum(L)-max(L)):
    print('Yes')
else:
    print('No')

Solution (Python):
import numpy as np
import sys

n = int(input())
l = np.array([int(x) for x in input().split()])
if np.max(l) * 2 < np.sum(l):
	print("Yes")
else:
	print("No")

Solution (Python):
N = int(input())
L = list(sorted(map(int, input().split())))

print("Yes" if L[N-1] < sum(L[:N-1]) else "No")

Solution (Python):
n = int(input())
l = list(map(int, input().split()))

max_suffix = 0
for i in range(n):
    if l[max_suffix] < l[i]: max_suffix = i

total = 0
for i in range(n):
    if i == max_suffix: continue
    else: total += l[i]
    
if total > l[max_suffix]: print("Yes")
else: print('No')

Solution (Python):
import sys
import os
import math

ii = lambda: int(sys.stdin.buffer.readline().rstrip())
il = lambda: list(map(int, sys.stdin.buffer.readline().split()))
fl = lambda: list(map(float, sys.stdin.buffer.readline().split()))
iln = lambda n: [int(sys.stdin.buffer.readline().rstrip()) for _ in range(n)]

iss = lambda: sys.stdin.buffer.readline().decode().rstrip()
sl = lambda: list(map(str, sys.stdin.buffer.readline().decode().split()))
isn = lambda n: [sys.stdin.buffer.readline().decode().rstrip() for _ in range(n)]

MOD = 10 ** 9 + 7


def main():
    if os.getenv("LOCAL"):
        sys.stdin = open("input.txt", "r")

    N = ii()
    L = sorted(il())[::-1]
    print('Yes' if sum(L[:1]) < sum(L[1:]) else 'No')



if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())
L = list(map(int, input().split()))

if max(L) < sum(L) - max(L):
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
L = list(map(int, input().split()))
if max(L) < sum(L) - max(L):
    print('Yes')
else:
    print('No')

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
l=sorted(l,reverse=True)
cou=sum(l)-l[0]

if l[0]<cou:
  print('Yes')
else:
  print('No')

Solution (Python):
input()
l=list(map(int,input().split()))
print('Yes' if 2*max(l)<sum(l) else 'No')

Solution (Python):
input()
l=list(map(int,input().split()))
print('Yes' if 2*max(l)<sum(l) else 'No')

Solution (Python):

N = int(input())
L = list(map(int, input().split()))
if max(L) < (sum(L)-max(L)):
    print("Yes")
else:
    print("No")

Solution (Python):
n=int(input())
N=list(map(int,input().split()))

max_n=max(N)
N.remove(max_n)
print("Yes" if max_n<sum(N) else "No")

Solution (Python):
n = int(input())
L = list(map(int, input().split()))
L.sort(reverse=True)
if max(L) < sum(L[1:]):
    print('Yes')
else:
    print('No')

Solution (Python):
N = int(input())
Ls = list(map(int, input().split()))

sum = 0

for i in range(N):
    sum += Ls[i]

if max(Ls)*2 < sum:
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
l = list(map(int, input().split()))
print('Yes' if max(l) < sum(l) - max(l) else 'No')

Solution (Python):













n = int(input())
arrL = list(map(int,input().split()))

longest = max(arrL)
hokasum = sum(arrL) - longest

if longest<hokasum:
    ans = "Yes"
else:
    ans = "No"

print(ans)

Solution (Python):
n = int(input())
l = list(map(int, input().split()))

l.sort(reverse=True)

if l[0] < sum(l[1:]):
    print('Yes')
else:
    print('No')

Solution (Python):
N=int(input())
L=list(map(int, input().split()))

if max(L)<sum(L)-max(L):
  print('Yes')
else:
  print('No')

Solution (Python):
import sys
N = int(sys.stdin.readline().rstrip())
l = list(map(int, sys.stdin.readline().rstrip().split()))
 
lm = 0
L = 0
for n in range(N):
  if l[n] > lm:
    L += lm
    lm = l[n]
  else:
    L += l[n]
    
if lm < L:
  print('Yes')
else:
  print('No')

Solution (Python):
def nyu():
    N = int(input())
    L = list(map(int,input().split()))
    L.sort()

    return N,L

def check(N,L):
    sum =0 

    for n in range(N-1):
        sum += L[n]
    if sum > L[N-1]:
        print("Yes")
    else:
        print("No")
    



N,L =nyu()
check(N,L)

Solution (Python):
n=int(input())
l=list(map(int, input().split()))
l.sort()
a=l.pop()
t=0
for i in range(len(l)):
  t+=l[i]
if a<t:
  print('Yes')
else:
  print('No')

Solution (Python):
N,L=open(0);L=sorted(map(int,L.split()));print('YNeos'[sum(L[:-1])<=L[-1]::2])

Solution (Python):
n=int(input())
L=list(sorted(map(int,input().split())))
m=L[-1]
if sum(L)>2*m:
    print("Yes")
else:
    print("No")

Solution (Python):
n =int(input())
l =list(map(int ,input().split()))
if sum(l)- max(l) >max(l):
    print("Yes")
else:
    print("No")

Solution (Python):
input()
L = list(map(int, input().split()))
print("Yes" if sum(L) > 2*max(L) else "No")

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
if max(a)*2 < sum(a):
  print("Yes")
else:
  print("No")

Solution (Python):
N = int(input())
L = list(map(int, input().split()))
print("Yes" if max(L) < sum(L)-max(L) else "No")

Solution (Python):
n=input()
L=sorted(list(map(int,input().split())))
if sum(L[:-1])>L[-1]:print("Yes")
else:print("No")

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
l=sorted(l)
if sum(l[0:n-1])>l[n-1]:
    print("Yes")
else:
    print("No")

Solution (Python):
n=int(input())
L=[int(i) for i in input().split()]
L.sort()
Lng=L.pop()
if Lng < sum(L):
  print("Yes")
else:
  print("No")

Solution (Python):
n=int(input())
l=[int(i) for i in input().split()]
l.sort()

longest=l.pop()
remain=sum(l)
if longest<remain:
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
l = list(map(int, input().split()))

l.sort()

max_num = l.pop(-1)

if max_num < sum(l):
    print('Yes')
else:
    print('No')

Solution (Python):
import sys
input = lambda: sys.stdin.readline().rstrip()

N = int(input())

L = list(map(int, input().split()))

if max(L) < sum(L) - max(L):
    print("Yes")
else:
    print("No")

Solution (Python):
N=int(input())
L=list(map(int,input().split()))
L2=sorted(L)
length2=sum(L2[:-1])
if length2>L2[-1]:
  print("Yes")
else:
  print("No")

Solution (Python):
n = int(input())
L = list(map(int,input().split()))
for l in L:
  if sum(L) - l <= l:
    print('No')
    exit()
print('Yes')

Solution (Python):
a = int(input())
b = input().split()
b_list = []
for i in range(a):
    b_list.append(int(b[i]))
c = max(b_list)
if sum(b_list)-c * 2>0:
    print('Yes')
else:
    print('No')

Solution (Python):
a = int(input())
b = [int(i) for i in input().split(" ")]
Max = max(b)
c = -Max
for i in range(a):
    c+=b[i]
 
if Max<c:
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())

L= list(map(int, input().split()))

if max(L)<sum(L)-max(L):
  print('Yes')
else:
  print('No')

Solution (Python):
n = int(input())
l = list(map(int,input().split()))
l.sort(reverse=True)

if l[0] < sum(l[1:]):
  print("Yes")
else:
  print("No")

Solution (Python):
N=int(input())
L=list(map(int,input().split()))
x=max(L)
sum=0
i=0
for i in range(N):
  sum+=L[i]
  i+=1
y=sum-x
if x<y:
  print('Yes')
else:
  print('No')

Solution (Python):

import sys
read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 7)

n = readline()
l = list(map(int, readline().split()))
print('Yes' if sum(l) > 2 * max(l) else 'No')

Solution (Python):
N = int(input())
L = [int(i) for i in input().split()]
l = max(L)
L.remove(l)
if sum(L) > l:
  print("Yes")
else:
  print("No")

Solution (Python):
_ = input()
*l, m = sorted(map(int, input().split()))
print("Yes" if sum(l) > m else "No")

Solution (Python):
N=int(input())
List=list(map(int, input().split()))

if 2*max(List) < sum(List):
	print("Yes")
else:
	print("No")

Solution (Python):
n=int(input())
l=[int(i) for i in input().split()]
print("Yes" if sum(l)-2*max(l)>0 else "No")

Solution (Python):
N=int(input())
L=list(map(int,input().split()))
L.sort(reverse=True)
total=0
for i in range(1,N):
  total+=L[i]
if L[0]<total:
  print('Yes')
else:
  print('No')

Solution (Python):

N = int(input())
L = list(map(int, input().split()))

max_L = max(L)
sum_L = sum(L)

if max_L < sum_L-max_L:
    print("Yes")
else:
    print("No")

Solution (Python):


import sys
import math
from bisect import bisect_right as br
from bisect import bisect_left as bl
sys.setrecursionlimit(2147483647)
from heapq import heappush, heappop,heappushpop
from collections import defaultdict
from itertools import accumulate
from collections import Counter
from collections import deque
from operator import itemgetter
from itertools import permutations
mod = 10**9 + 7
inf = float('inf')
def I(): return int(sys.stdin.readline())
def LI(): return list(map(int,sys.stdin.readline().split()))

n = I()
l = LI()
if sum(l) - max(l) > max(l):
    print('Yes')
else:
    print('No')

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
if sum(l)>2*max(l):
  print("Yes")
else:
  print("No")

Solution (Python):
N = int(input())
L = list(map(int,input().split()))
if sum(L) > 2 * max(L): print("Yes")
else: print("No")

Solution (Python):
n = int(input())

p = list(map(int, input().split()))

if max(p) < sum(p) - max(p):
    print('Yes')
else:
    print('No')

Solution (Python):

from collections import Counter
def inputlist(): return [int(j) for j in input().split()]

N = int(input())
L = inputlist()
L.sort()
s = 0
for i in range(N-1):
    s += L[i]
if s > L[-1]:
    print("Yes")
else:
    print("No")

Solution (Python):
N = int(input())
L = list(map(int,input().split()))
print("Yes" if max(L) < sum(L)/2 else "No")