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):
N = int(input())
li = [int(x) for x in input().split()]
lmax = max(li)
a = sum(li) - lmax
if a > lmax:
  print("Yes")
else:
  print("No")

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

Solution (Python):
N = int(input())
Ln= map(int,input().split())
Llist = list(Ln)
L_max = max(Llist)
Llist.remove(L_max)
if L_max < sum(Llist):
    print("Yes")
else:
    print("No")

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

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

Solution (Python):

N = int(input())
L = map(int, input().split())
sumL = 0
maxL = -1
for Li in L:
    sumL += Li
    if Li > maxL:
        maxL = Li
    
sumL -= maxL

if maxL < sumL:
    print("Yes")
else:
    print("No")

Solution (Python):
kaku = input()
s_list = input().split(' ')
if not int(kaku) == len(s_list):
    print('No')
else:
    hen_list = [int(x) for x in s_list]
    m = max(hen_list)
    total = sum(hen_list)
    if m < total - m:
            print('Yes')
    else:
        print('No')

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

l.sort()

for i in range(n-1):
    sum=sum+l[i]
if(l[n-1]<sum):
    print("Yes")
else:
    print("No")

Solution (Python):
n = input()
L = list(map(int, input().split()))
sum_l = 0
for sl in L:
  sum_l += sl
print('Yes') if max(L) < sum_l - max(L) 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):



def main():
    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[0:n-1]) > L.pop():
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
l = sorted([int(i) for i in input().split()])
cmp = l.pop(-1)
if cmp<sum(l):
  print('Yes')
else:
  print('No')

Solution (Python):


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

maxL = max(L)

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

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

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

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

Solution (Python):
Sum=0
Max=0
n=int(input())
a=input().split()
for i in range(n):
    a[i]=int(a[i])
    Sum+=a[i]
    Max=max(Max,a[i])
if Max<Sum/2:
    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 = input()
l_ls = sorted(list(map(int, input().split())))
if l_ls[-1] < sum(l_ls[:-1]):
    print('Yes')
else:
    print('No')

Solution (Python):

try:
    N = int(input())
    Li = [int(x) for x in input().split()]
    Li = sorted(Li, reverse=True)
    if N < 3 or N > 10:
        exit()
    for x in Li:
        if x < 1 or x > 100:
            exit()
    if N is not len(Li):
        exit()
    maxL = Li[0]
    a = 0

    for i in range(1, N):
        a += Li[i]
    if maxL < a:
        print("Yes")
    elif maxL >= a:
        print("No")
except ValueError:
    exit()

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

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

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

Solution (Python):
n = int(input())
length = list(map(int, input().split()))
lengthsum = sum(length)
ans = "Yes"
for l in length:
    if l >= lengthsum - l:
        ans = "No"
        break
print(ans)

Solution (Python):
a,b=int(input()), sorted([int(x) for x in input().split()],reverse=1)
print("Yes" if b[0]<sum(b[1:a]) else "No")

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

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

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

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

  Ls = sorted(Ls, reverse=True)
  N_max = Ls[0]
  N_sum = sum(Ls[1:])
  if N_max < N_sum:
    print('Yes')
  else:
    print('No')



main()

Solution (Python):
input();s=map(int,raw_input().split());print'YNeos'[sum(s)-max(s)*2<1::2]

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

nums = list(map(lambda x: int(x), L))

nums.sort()

max = nums.pop(-1)

sum = sum(nums)

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

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()))

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

Solution (Python):
n = input()

l = [int(i) for i in input().split()] 
maximum = max(l)

if((sum(l) - maximum) > maximum):
    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())
a = input().split()
i = 0
while i < n:
  a[i] = int(a[i])
  i = i + 1 
 
i = 0
while i < n:
  j = i + 1
  while j < n:
    if a[i] < a[j]:
      temp = a[i]
      a[i] = a[j]
      a[j] = temp
    j = j + 1
  i = i + 1
 
sums = sum(a)

if(sums - a[0] > a[0]):
  print("Yes")
else:
  print("No")
sum = sum(a)

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

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

l_max = max(l)
l_sum = sum(l)

if l_max < l_sum - l_max:
	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):
a = input()
li = list(map(int, input().split()))
li.sort()
M = li[-1]
hoka = sum(li[:-1])

if M < hoka:
    print('Yes')
else:
    print('No')

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

Solution (Python):
N = int(input())
Ls = list(map(int,input().split()))
Ls.sort()
sum_n_1 = sum(Ls)-Ls[-1]
if sum_n_1 > Ls[-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 print("No")

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

Solution (Python):
n = int(input())
s = list(map(int,input().split()))
if max(s)<sum(s)-max(s):
  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())

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

B = sum(A) - (max(A) * 2)

if(B > 0):
    print("Yes")
else:
    print("No")

Solution (Python):
n = int(input())
N = list(map(int,input().split()))
N.sort()
A  = N[n-1]
N.pop(n-1)
B = 0
for i in range(len(N)):
    B += N[i]
if A < B:
    print("Yes")
else :
    print("No")

Solution (Python):
import sys

N = int(sys.stdin.readline().strip())

line = sys.stdin.readline()
nums = [int(x) for x in line.strip().split(' ')]

assert N == len(nums)
nums.sort()

if nums[-1] < sum(nums[:-1]):
  print('Yes')
else:
  print('No')

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

m = max(L)
s = sum(L) - m

if m < s:
    print("Yes")
else:
    print("No")

Solution (Python):
input()
l=[int(i) for i in input().split()]
l.sort()
if l[-1]<sum(l[:-1]):
    print("Yes")
else:
    print("No")

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

sumdatas = sum(datas)
maxdatas = max(datas)

if maxdatas < sumdatas - maxdatas:
  print("Yes")
else:
  print("No")

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

L_max = L[-1]
L_sum = sum(L) - L_max

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

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

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

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

Solution (Python):
from functools import reduce
from operator import add

N = input()

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

MAX = max(L)

if reduce(add, L) - 2 * MAX > 0:
  print("Yes")
else:
  print("No")

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

L.sort(reverse=True)

if 2*L[0]<sum(L):
    print "Yes"
else:
    print "No"

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

s = sum(inp)-max(inp)
m = max(inp)

if s > m:
    print("Yes")
else:
    print("No")

Solution (Python):
n=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()))
max_L = L.pop(L.index(max(L)))
if max_L < sum(L):
    ans = True
else:
    ans = False
if ans:
    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):
N=int(input())
listL=list(map(int,input().split()))
a,b=max(listL),sum(listL)
if a < b-a :
    print('Yes')
else :
    print('No')

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

maximum = max(LN)
ans = 'Yes' if maximum < sum(LN) - maximum else 'No'
print(ans)

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

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
s=0
for i in range(0,n):
  s+=a[i]
i=0
p="Yes"
while(i<n):
  if s-a[i]<=a[i]:
    p="No"
  i+=1
print(p)

Solution (Python):
N = input()
a = list(map(int, input().split()))
amax = max(a)
a.remove(amax)
sum = 0
for i in a:
  sum += i
if amax < sum:
  print("Yes")
else:
  print("No")

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

l_max = np.max(L)
l_i_max = np.argmax(L)
sum = 0

for i, l in enumerate(L):
  if i == l_i_max:
    continue
  sum += l

if l_max < sum:
  print("Yes")
else:
  print("No")

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

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

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

L_max=max(L_list)
L_list.remove(L_max)

if(sum(L_list)>L_max):
    print("Yes")
else:
    print("No")

Solution (Python):
import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,random,time,copy,functools

sys.setrecursionlimit(10**7)
inf = 10**20
eps = 1.0 / 10**10
mod = 10**9+7
dd = [(-1,0),(0,1),(1,0),(0,-1)]
ddn = [(-1,0),(-1,1),(0,1),(1,1),(1,0),(1,-1),(0,-1),(-1,-1)]

def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def I(): return int(sys.stdin.readline())
def F(): return float(sys.stdin.readline())
def S(): return input()
def pf(s): return print(s, flush=True)


def main():
    n = I()
    l = LI()
    m = max(l)
    s = sum(l)
    if m * 2 < s:
        return 'Yes'

    return 'No'



print(main())

Solution (Python):
import sys
n= int(input())
l = sorted(list(map(int, input().split())))
s = sum(l)

for x in l:
  if x>=s-x:
    print("No")
    sys.exit()
print("Yes")

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

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

if sum(A) - max(A) > max(A):
  print('Yes')
else:
  print('No')

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

Solution (Python):
import sys

def main():
  input = sys.stdin.readline
  n = int(input())
  l = [int(a) for a in input().split()]
  m = max(l)
  s = sum(l) - m
  if s > m:
    print('Yes')
  else:
    print('No')


if __name__ == '__main__':
  main()

Solution (Python):

from sys import stdin


s_in = lambda: stdin.readline()[:-1]  
d_in = lambda: int(stdin.readline())  
ds_in = lambda: list(map(int, stdin.readline().split()))  


N = d_in()
L_list = ds_in()

S = sum(L_list)
if max(L_list) * 2 < S:
    print('Yes')
else:
    print('No')

Solution (Python):
n = int(input())
nums = list(map(int, input().split()))
mx = nums.pop(nums.index(max(nums)))
if mx < sum(nums):
  print("Yes")
else :
  print("No")

Solution (Python):
N = int(input())
el = list(map(int, input().split()))
el.sort(reverse=True)
mle = el[0]
els = sum(el) - mle
print("Yes") if mle < els else print("No")

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
s=sum(a)

tst=lambda x:x*2<s
print('Yes' if all(list(map(tst,a))) else 'No')

Solution (Python):


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

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

lines=0
L.sort()
for i in range(len(L)-1):
    lines+=L[i]

if lines > L[-1]:
    print("Yes")
else:
    print("No")

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

n = len(l)

lm = 0
ls = 0
for i in range(0, n):
  if lm < l[i]:
    lm = l[i]
  ls = ls + l[i]
ls = ls - lm

if lm < ls:
  print("Yes")
else:
  print("No")

Solution (Python):
n = int(input())
L = list(map(int,input().split()))
L.sort()
largest = L.pop()
if largest < sum(L):
  print("Yes")
else:
  print("No")

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

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

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

Solution (Python):
from sys import stdin
N = int(stdin.readline().rstrip())
L = [int(x) for x in stdin.readline().rstrip().split()]

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

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

Ls.sort()

maxL = Ls[-1]
sums = sum(Ls[:-1])
if sums > maxL:
    print('Yes')
else:
    print('No')

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

Solution (Python):



def main():
  x = int(input())
  ls = list(map(int, input().split()))
  ls.sort()
  if ls[-1] < sum(ls[:-1]):
    print('Yes')
  else:
    print('No')
  pass

if __name__=='__main__':
  main()

Solution (Python):
print((lambda l:['No','Yes'][sum(l[:-1])>l[-1]])(sorted(list(map(int,[input()]+input().split()))[1:])))

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

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

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

m = max(l)
l.remove(m)
if m < sum(l):
    print('Yes')
else:
    print('No')

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

if max(L_list) < sum(L_list) - max(L_list):
    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):
int(input())
L=list(map(int,input().split()))
print("Yes" if sum(L)>2*max(L) else "No")

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

Solution (Python):
int(input())
l=list(map(int,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):
N = int(input())
l = list(map(int, input().split()))

ml = max(l)
rest = sum(l) - ml
print('Yes' if ml < rest else 'No')

Solution (Python):
_,*s=map(int,open(0).read().split());print('YNeos'[sum(s)-max(s)*2<1::2])

Solution (Python):
input();*s,=map(int,input().split());print('YNeos'[sum(s)-max(s)*2<1::2])

Solution (Python):
n = int(input())
l = sorted([i for i in map(int, input().split())])
print("YNeos"[l[-1] >= sum(l[:-1])::2])

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())
list_L = list(map(int, input().split()))

max_ = list_L.pop(list_L.index(max(list_L)))

if max_ >= sum(list_L):
    print("No")
else:
    print("Yes")

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

L.sort()

s = sum(L)

print("Yes" if s - 2 * L[-1] > 0 else "No")

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

max_length = max(L)
other_length = sum(L) - max_length

if max_length < other_length:
  print("Yes")
else:
  print("No")

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


def main() -> None:
    L.sort()
    longest = L.pop()
    if longest < sum(L):
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    main()

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())
lines = list(map(int,input().split()))
max_line_idx = lines.index(max(lines))
max_line = max(lines)
lines.pop(max_line_idx)
if sum(lines) > max_line:
    print("Yes")
else:
    print("No")

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

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

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

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

Solution (Python):



n=int(input())

x=[int(i) for i in input().split()]
x.sort()
if sum(x) > 2*x[-1]:
    print('Yes')
else:
    print('No')

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

Solution (Python):
def main():
  N = int(input())
  len_list = sorted(list(map(int, input().split())), reverse=True)
  max_len = len_list[0]
  sum_len = 0
  
  for i in range(1,N):
    sum_len += len_list[i]
    
  if max_len < sum_len:
    print('Yes')
  else:
    print('No')

main()

Solution (Python):




def solveProblem(lengthList):
	sortedList = sorted(lengthList,reverse=True)
	allIntegerSum = sum(lengthList)
	maxInteger = sortedList.pop(0)
	anotherIntegerSum = allIntegerSum - maxInteger
	if maxInteger < anotherIntegerSum:
		answer="Yes"
	else:
		answer="No"
	return answer

if __name__ == '__main__':
	_ = input()
	lList = list(map(int,input().strip().split(' ')))
	solution = solveProblem(lList)
	print("{}".format(solution))

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

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

Ld = sorted(L, reverse=False)

L_other=0
for i in range(N-1):
  L_other += Ld[i]

if (Ld[N-1] < L_other):
  print('Yes')
else:
  print('No')

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

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

Solution (Python):
from sys import stdin
n = int(stdin.readline().rstrip())
l = [int(x) for x in stdin.readline().rstrip().split()]
max = max(l)
sum = sum(l, -1*max)
print("Yes") if sum > max else print("No")

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

Solution (Python):
N=int(input())
a=input()
num=[]
n=a.split()
for i in(n):
  num.append(int(i))

num.sort()
b=0
for i in range(len(num)-1):
  b+=num[i]
if(num[len(num)-1]<b): print('Yes')
else: print('No')

Solution (Python):
n = int(input())
b = list(map(int, input().split()))
c = max(b)
s = sum(b)

if c * 2 - s < 0:
	print('Yes')
else:
	print('No')

Solution (Python):
from sys import stdin
n = int(stdin.readline().rstrip())
l = [int(x) for x in stdin.readline().rstrip().split()]
max = max(l)
sum = sum(l, -1*max)
if sum > max:
  print("Yes")
else:
  print("No")

Solution (Python):
s = int(input())
A = list(map(int, input().split())) 
m = max(A)
if sum(A) - int(m) > int(m):
    print("Yes")
elif sum(A) - int(m) <= int(m):
    print("No")

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

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

L.sort()
L.reverse()

if L[0] < sum(L)-L[0]:
    print('Yes')
else:
    print('No')

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

L0 = sum(L[:-1])
L1 = L[-1]
print('Yes' if L0 > L1 else 'No')

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

lmax = max(l)
l.remove(lmax)
if sum(l) > lmax:print("Yes")
else: print("No")

Solution (Python):
from sys import stdin
 
n = int(stdin.readline().rstrip())
data = list(map(int, stdin.readline().rstrip().split()))
 
def is_s(hens):
  m = max(hens)
  hens.remove(m)
  if m < sum(hens):
  	return "Yes"
  else:
    return "No"
 
print(is_s(data))

Solution (Python):
n=int(input())
l=[int(i) for i in input().split()]
ans=0
lmax=max(l)
maxindex=l.index(lmax)

for i in range(n):
    if i!=maxindex:
        ans+=l[i]

if ans>lmax:
    print('Yes')
else:
    print('No')

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

L_sum = sum(L)

res = True
for l in L:
    if ((L_sum - l) <= l):
        res = False

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

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




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



    




s = sum(L)
m = max(L)







if (m < s - m):
    print('Yes')
else:
    print('No')

Solution (Python):



N = int(input())


l = list(map(int, input().split()))
max = max(l)



num = 0
for i in l:
    num=i+num
num = num-max


if num > max:
    print("Yes")
else:
    print("No")

Solution (Python):
n, = [int(i) for i in input().strip().split(" ")]
ls = [int(i) for i in input().strip().split(" ")]
l = max(ls)
l2 = sum(ls)
if l2 - l > l:
    print("Yes")
else:
    print("No")

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

if max(arr) * 2 - sum(arr) >= 0:
    print('No')
else:
    print('Yes')

Solution (Python):
if __name__ == '__main__':
    n = int(input())
    ls = sorted((int(x) for x in input().split()), reverse=True)
    if ls[0] < sum(ls[1:]):
        print('Yes')
    else:
        print('No')

Solution (Python):
def main() :
    N = int(input())
    l_list = [int(i) for i in input().split()]
    max_len = max(l_list)
    sum_len = sum(l_list) - max_len

    if (max_len < sum_len) :
        print("Yes")
    else :
        print("No")

main()

Solution (Python):
N = int(input())
L = input().split(" ")
max = 0
sum = 0
tmp = 0
for i in range(N):
    tmp = int(L[i])
    sum += tmp
    if tmp > max:
        max = tmp

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

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

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

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

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

new_list = sorted(list, reverse=True)

x = 0
for i in new_list[1:len(new_list)]:
    x += i

if new_list[0] < x:
    print('Yes')
else:
    print('No')

Solution (Python):
N = input()
L_i = list(int (x) for x in input().split())

Lmax = max(L_i)
if((int(sum(L_i)) - Lmax) > Lmax):
    print("Yes")
else:
    print("No")

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

m = max(l)

s = 0
find = False
for num in l:
    if num == m and not find:
        find = True
    else:
        s += num

if m < s:
    print("Yes")
else:
    print("No")

Solution (Python):

import bisect
import heapq
import math
import random
import sys
from collections import Counter, defaultdict, deque
from decimal import ROUND_CEILING, ROUND_HALF_UP, Decimal
from functools import lru_cache, reduce
from itertools import combinations, combinations_with_replacement, product, permutations
from operator import add, mul, sub

sys.setrecursionlimit(10000)


def read_int():
    return int(input())


def read_int_n():
    return list(map(int, input().split()))


def read_float():
    return float(input())


def read_float_n():
    return list(map(float, input().split()))


def read_str():
    return input().strip()


def read_str_n():
    return list(map(str, input().split()))


def error_print(*args):
    print(*args, file=sys.stderr)


def mt(f):
    import time

    def wrap(*args, **kwargs):
        s = time.time()
        ret = f(*args, **kwargs)
        e = time.time()

        error_print(e - s, 'sec')
        return ret

    return wrap


@mt
def slv(N, L):
    return 'Yes' if sum(L) - max(L) > max(L) else 'No'


def main():
    N = read_int()
    
    
    L = read_int_n()
    print(slv(N, L))


if __name__ == '__main__':
    main()

Solution (Python):
n=int(input())
a=str(input())
l=[]
l=list(map(int,a.split()))

l.sort()
l.reverse()
plus=0
for i in range(n):
    if i==0:
        pass
    else:
        plus+=l[i]
if l[0]<plus:
    print('Yes')
else:
    print('No')

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

l.sort()

a = 0
i = 0
while i < n - 1:
  a += l[i]
  i += 1

print("Yes" if l[n-1] < a else "No")

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

Solution (Python):
n = int(input())
l = list(map(int, input().split()))
max_num = 0
max_index = 0
total = 0

for i in range(n):
  if max_num < l[i]:
    max_num = l[i]
    max_index = i

l.pop(max_index)

for i in range(n - 1):
  total += l[i]

if total > max_num: print("Yes")
else: print("No")

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

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

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

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

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

Solution (Python):
def judge(n,l):
    for i in range(n):
        s = 0
        for j in range(n):
            if(j!=i):
                s += l[j]
        if(s<=l[i]):
            print('No')
            return
    print('Yes')
    return

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

Solution (Python):

import sys



def solve(lines):
    N = int(lines.pop(0))
    L = list(map(int, lines.pop(0).split(' ')))
    L.sort()
    longest = L.pop(-1)
    if longest < sum(L):
        print('Yes')
    else:
        print('No')




lines = [x.strip() for x in sys.stdin.readlines()]




solve(lines)

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

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

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

L_sum = sum(L)

if L_sum - L_max > L_max:
    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 = [int(i) for i in input().split()]

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