Harryxun/stf_run huggingface dataset:
import random
random.seed(0)

D = int(input())
C = [int(i) for i in input().split()]
S = [[int(i) for i in input().split()] for j in range(D)]

def score_calc(T):
    total = 0
    last = [0] * 26
    for i in range(1, D+1):
        t = T[i-1]
        total += S[i-1][t-1]
        last[t-1] = i
        for j in range(26):
            total -= C[j] * (i - last[j])
    return total
    
N = 1000
T_ls = [[random.randint(1, 26) for i in range(D)] for j in range(N)]
best_score = 0
ans = []
for i in range(N):
    if score_calc(T_ls[i]) > best_score:
        best_score = score_calc(T_ls[i])
        ans = T_ls[i]

for i in range(D):
    print(ans[i])

### FIXED CODE ###

D = int(input())
C = [int(i) for i in input().split()]
S = [[int(i) for i in input().split()] for j in range(D)]

total = 0
last = [0] * 26
ans = []
for i in range(1, D+1):
    score = [0] * 26
    for t in range(26):
        score[t] += S[i-1][t-1]
        for j in range(26):
            if j != t:
                score[t] -= C[j] * (i - last[j])
    total += max(score)
    last[score.index(max(score))] = i
    ans.append(score.index(max(score))+1)

for i in range(D):
    print(ans[i])
from collections import deque

N=int(input())
a=[0]*(N-1)
b=[0]*(N-1)
c=[0]*(N-1)
L=[ [] for _ in range(N)]
for i in range(N-1):
  a[i],b[i],c[i]= map(int,input().split())
  L[a[i]-1].append((b[i]-1,c[i]))
  L[b[i]-1].append((a[i]-1,c[i]))
Q,K= map(int,input().split())
         
#Lの中のitemの0は接続先、1は距離

d=[ -1 for i in range(N)]

def BFS(x):
  v=deque([x])
  d[x]=0
  
  while len(v)>0:
    s=v.popleft() #sはint
    for item in L[s]:
      if d[item[0]]==-1:
        d[item[0]]=d[s]+item[1]
        v.append(item[0])
BFS(K-1)

x=[0]*N
y=[0]*N
for i in range(Q):
  x[i],y[i] = map(int,input().split())
  print(d[x[i]-1]+d[y[i]-1])

### FIXED CODE ###

from collections import deque

N=int(input())
a=[0]*(N-1)
b=[0]*(N-1)
c=[0]*(N-1)
L=[ [] for _ in range(N)]
for i in range(N-1):
  a[i],b[i],c[i]= map(int,input().split())
  L[a[i]-1].append((b[i]-1,c[i]))
  L[b[i]-1].append((a[i]-1,c[i]))
Q,K= map(int,input().split())
         
#Lの中のitemの0は接続先、1は距離

d=[ -1 for i in range(N)]

def BFS(x):
  v=deque([x])
  d[x]=0
  
  while len(v)>0:
    s=v.popleft() #sはint
    for item in L[s]:
      if d[item[0]]==-1:
        d[item[0]]=d[s]+item[1]
        v.append(item[0])
BFS(K-1)

x=[0]*Q
y=[0]*Q
for i in range(Q):
  x[i],y[i] = map(int,input().split())
  print(d[x[i]-1]+d[y[i]-1])
NL = input()
N = int(NL[0])
L = int(NL[2])
apple = []
apple_abs = []
sum = 0
for i in range(1,N+1):
  apple.append(L+i-1)
  apple_abs.append(abs(L+i-1))

apple_min = min(apple_abs)

for i in apple:
  if abs(i) = apple_min:
    continue
  sum += i
print(sum)

### FIXED CODE ###

NL = input().split()
N = int(NL[0])
L = int(NL[1])
apple = []
apple_abs = []
sum = 0
for i in range(1,N+1):
  apple.append(L+i-1)
  apple_abs.append(abs(L+i-1))

apple_min = min(apple_abs)

for i in apple:
  if abs(i) == apple_min:
    continue
  sum += i
print(sum)
from math import pi
r = int(input())
a = pi*r*r
b = 2*pi*r
print(a,b)


### FIXED CODE ###

from math import pi
r = float(input())
a = pi*r*r
b = 2*pi*r
print(a,b)
s=input()
t=input()
for c in range(3):
    if s[c]!=t[2-c]:
        print("NO")
        sys.exit(0)
print("YES");


### FIXED CODE ###

import sys
s=input()
t=input()
for c in range(3):
    if s[c]!=t[2-c]:
        print("NO")
        sys.exit(0)
print("YES");
A, B= map(int, input().split())

if A==1 & B==!:
    print("Draw")
elif A==1 :
    print("Alice")
elif B==1 :
    print("Bob")
elif A > B:
    print("Alice")
elif B>A:
    print("Bob")
else :
    print("Draw")

### FIXED CODE ###

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

if A==1:
    A = 14

if B==1:
    B = 14

if A > B:
    print("Alice")
elif B > A:
    print("Bob")
else :
    print("Draw")
arr = []
for i in range(3):
	te = list(map(int,input().split()))
	arr.append(te)
n = int(input())
check = []
for i in range(n):
	x = int(input())
	for j in range(3):
		for k in range(3):
			if arr[j][k]==x:
				arr[j][k] = 0
yes = False
for j in range(3):
	c = 0
	for k in range(3):
		if arr[j][k]==0:
			c+=1
	if c==3:
		yes = True
		break
	
if yes==False:
	for j in range(3):
		c = 0
		for k in range(3):
			if arr[k][j]==0:
				c+=1
		if c==3:
			yes = True
			break
if yes==False:
	c = 0
	for j in range(3):		
		if arr[j][j]==0:
			c+=1
	if c==3:
		yes = True
if yes==False:
	c = 0
	for j in range(3):		
		if arr[j][2-j]==0:
			c+=1
	if c==3:
		yes = True
if yes:
	print("YES")
else:
	print("NO")					

### FIXED CODE ###

arr = []
for i in range(3):
	te = list(map(int,input().split()))
	arr.append(te)
n = int(input())
check = []
for i in range(n):
	x = int(input())
	for j in range(3):
		for k in range(3):
			if arr[j][k]==x:
				arr[j][k] = 0
yes = False
for j in range(3):
	c = 0
	for k in range(3):
		if arr[j][k]==0:
			c+=1
	if c==3:
		yes = True
		break
	
if yes==False:
	for j in range(3):
		c = 0
		for k in range(3):
			if arr[k][j]==0:
				c+=1
		if c==3:
			yes = True
			break
if yes==False:
	c = 0
	for j in range(3):		
		if arr[j][j]==0:
			c+=1
	if c==3:
		yes = True
if yes==False:
	c = 0
	for j in range(3):		
		if arr[j][2-j]==0:
			c+=1
	if c==3:
		yes = True
if yes:
	print("Yes")
else:
	print("No")
a,b = input().split()
c = a * b
d = c % 2

if d == 1:
    print("Odd")
else:
    print("Even")

### FIXED CODE ###

a,b = input().split()
c = int(a) * int(b)
d = c % 2
 
if d == 1:
    print("Odd")
else:
    print("Even")
n, m = map(int, input().split())
x = []
y = []
z = []
f = [[] for _ in range(8)]
for i in range(n):
    a = input()
    a = a.split(' ')
    a = list(map(int, a))
    xi = a[0]
    yi = a[1]
    zi = a[2]
    x.append(xi)
    y.append(yi)
    z.append(zi)
    fi = [0 for _ in range(8)]
    fi[0] = xi + yi + zi
    fi[1] = xi + yi - zi
    fi[2] = xi - yi + zi
    fi[3] = -xi + yi + zi
    fi[4] = xi - yi - zi
    fi[5] = -xi - yi + zi
    fi[6] = -xi + yi - zi
    fi[7] = -xi - yi - zi
    for j in range(8):
        f[j].append(fi[j])
def reversort(x):
    return list(reversed(sorted(x)))
f = list(map(reversort, f))
fmax = [0 for _ in range(8)]
for i in range(m):
    for j in range(8):
        fmax[j] += f[j][i]
print(max(fmax))

### FIXED CODE ###

a, b = map(int, input().split())
if a<=8 and b<=8:
    print('Yay!')
else:
    print(':(')
n,m,r=map(int,input().split());
a=n+r-n*m-1;b=r-n*m;
s=1;
if a<b||a<0||b<0:s=0;
else:
    if b>a-b:b=a-b;
	for i in range(b):s=s*(a-i)/(i+1);
print(s)


### FIXED CODE ###

n,m,r=map(int,input().split());
a=n+r-n*m-1;b=r-n*m;
s=1;
if a<b or a<0 or b<0:s=0;
else:
    if b>a-b:b=a-b;
    for i in range(b):s=s*(a-i)//(i+1);
print(s)
a = int(input())
b = input()
if a%2 == 0:
  print("Yes" if a[:(a/2)] == a[(a/2):] else "No")
else:
  print("No")

### FIXED CODE ###

a = int(input())
b = input()
if a%2 == 0:
  print("Yes" if b[:int(a/2)] == b[int(a/2):] else "No")
else:
  print("No")
#!/usr/bin python3
# -*- coding: utf-8 -*-

mod = 10**9+7
N = 10**5                   # 出力の制限
g1 = [1]*(N+1)              # 元テーブル
g2 = [1]*(N+1)              # 逆元テーブル
for i in range( 2, N + 1 ): # 準備
    g1[i] = ( g1[i-1] * i ) % mod
    g2[i] = ( g2[i-1] * pow(i,mod-2,mod) ) % mod

def nCr(n, r, mod):
    if ( r<0 or r>n ):
        return 0
    r = min(r, n-r)
    return g1[n] * g2[r] * g2[n-r] % mod

def main():
    K = int(input())
    S = input()
    Nk = len(S)
    ret = 0
    for i in range(K+1):
        ret += nCr(i+Nk-1, Nk-1, mod) * pow(25,i,mod) * pow(26,K-i,mod)
        ret %= mod
    print(ret)

if __name__ == '__main__':
    main()

### FIXED CODE ###

#!/usr/bin python3
# -*- coding: utf-8 -*-

def main():
    mod = 10**9+7
    K = int(input())
    S = input()
    Nk = len(S)
    ret = 0
    nCk = 1
    pw25 = 1
    pw26 = pow(26,K,mod)
    inv26 = pow(26,mod-2,mod)
    for i in range(K+1):
        ret += nCk * pw25 * pw26
        ret %= mod
        nCk *= (i+Nk) * pow(i+1,mod-2,mod)
        nCk %= mod
        pw25 = (pw25*25)%mod
        pw26 = (pw26*inv26)%mod

    print(ret)

if __name__ == '__main__':
    main()
l = sorted(map,input().split())
print((l[0]*l[1])//2)

### FIXED CODE ###

l = sorted(map(int,input().split()))
print((l[0]*l[1])//2)
results=[]
while True:
    a=input().split("\"")
    if a[0]==".":
        break
    b=input().split("\"")
    count=0
    for i,j in zip(range(len(a)),range(len(b)):
        for k,l in zip(a[2*i],b[2*j]):
            if(k!=l):
                count+=1
    if count==0:
        results.append(0)
    elif count==1:
        results.append(1)
    else:
        results.append(2)
for i in results:
    if i==0:
        print("IDENTICAL")
    if i==1:
        print("CLOSE")
    if i==2:
        print("DIFFERENT")
    



### FIXED CODE ###

results=[]
while True:
    a=input().split("\"")
    if a[0]==".":
        break
    b=input().split("\"")
    count1=0
    count2=0
    if len(a) != len(b):
        results.append(2)
    else:
        for i in range(len(a)):
            if(i%2==1):
                if len(a[i]) != len(b[i]):
                    count1+=1
                else:
                    for k,l in zip(a[i],b[i]):
                        if(k!=l):
                            count1+=1
            else:
                if len(a[i]) != len(b[i]):
                    count2+=1
                else:
                    for k,l in zip(a[i],b[i]):
                        if(k!=l):
                            count2+=1           
        if count1==0 and count2==0:
            results.append(0)
        elif count1==1 and count2==0:
            results.append(1)
        else:
            results.append(2)
for i in results:
    if i==0:
        print("IDENTICAL")
    if i==1:
        print("CLOSE")
    if i==2:
        print("DIFFERENT")
import sys
from math import factorial

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

N = ir()
K = ir()
length = len(str(N))

def F(length, K, N):
    if length < K:
        return 0
    if K == 0:
        return 1
    if length == 1: #この時、Kも1
        return N
    ret = 0
    top = int(str(N)[0])
    if length-K >= 1:
        ret += factorial(length-1) // factorial(K) // factorial(length-K-1) * 9 ** K # 一個前まで    
    ret += factorial(length-1) // factorial(K-1) // factorial(length-K) * (top-1) * 9 ** (K-1) # 一桁目がtopより小さい数  
    # 一桁目がtopと同じ数
    if K > 1: 
        N = int(str(N)[1:])
        length = len(str(N))
        ret += F(length, K-1, N)
    else:
        ret += 1 # 2000のような数
    return ret

answer = F(length, K, N)
print(answer)


### FIXED CODE ###

import sys
import numpy as np

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

def cmb(n, k):
    return fact[n] * fact_inv[k] % MOD * fact_inv[n-k] % MOD

def cumprod(arr, MOD):
    L = len(arr); Lsq = int(L**.5+1)
    arr = np.resize(arr, Lsq**2).reshape(Lsq, Lsq)
    for n in range(1, Lsq):
        arr[:, n] *= arr[:, n-1]; arr[:, n] %= MOD
    for n in range(1, Lsq):
        arr[n] *= arr[n-1, -1]; arr[n] %= MOD
    return arr.ravel()[:L]

def make_fact(U, MOD):
    x = np.arange(U, dtype=np.int64); x[0] = 1
    fact = cumprod(x, MOD)
    x = np.arange(U, 0, -1, dtype=np.int64); x[0] = pow(int(fact[-1]), MOD-2, MOD)
    fact_inv = cumprod(x, MOD)[::-1]
    return fact, fact_inv

r1, c1, r2, c2 = lr()
MOD = 10 ** 9 + 7
U = 2 * 10 ** 6 + 10
fact, fact_inv = make_fact(U,MOD)

answer = cmb(r2+c2+2, r2+1) - cmb(r2+1+c1, r2+1) - cmb(r1+c2+1, r1) + cmb(r1+c1, r1)
print(answer % MOD)

# 16
#!/usr/bin/env python
import sys
from collections import Counter
from itertools import permutations, combinations
from math import ceil, floor, gcd
sys.setrecursionlimit(10 ** 6)

def input():
    return sys.stdin.readline()[:-1]

def main():
    n = int(input())
    p = tuple(map(int, input().split()))
    q = tuple(map(int, input().split()))
    l = permutations(list(range(1, n+1)))
    if p == q:
        print(0)
    else:
        for idx, item in enumerate(l):
            if item == p:
                idp = idx
            elif item == q:
                idq = idx
        print(abs(idp - idq))

if __name__ == '__main__':
    main()

### FIXED CODE ###

#!/usr/bin/env python
import sys
from collections import Counter
from itertools import permutations, combinations
from fractions import gcd
from math import ceil, floor
sys.setrecursionlimit(10 ** 6)

def input():
    return sys.stdin.readline()[:-1]

def main():
    n = int(input())
    p = tuple(map(int, input().split()))
    q = tuple(map(int, input().split()))
    l = permutations(list(range(1, n+1)))
    if p == q:
        print(0)
    else:
        for idx, item in enumerate(l):
            if item == p:
                idp = idx
            elif item == q:
                idq = idx
        print(abs(idp - idq))

if __name__ == '__main__':
    main()
N, M = map(int, input().split())
A = list(map(int, input().split()))
 
check = ((1 / (4 * M)) * sum(A))
x = 0
for item in A:
    if item < check:
        x += 1
        ans = N - x
 
if ans >= M :
    print('Yes')
else:
    print('No')

### FIXED CODE ###

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

check = ((1 / (4 * M)) * sum(A))
x = 0
for item in A:
    if item < check:
        x += 1

ans = N - x

if ans >= M :
    print('Yes')
else:
    print('No')
def fibona(x):
    import math
    return (((1/2+math.sqrt(5)/2)**(x+1))-((1/2-math.sqrt(5)/2)**(x+1)))//math.sqrt(5)

def main():
    n, m = map(int,input().split())
    mlis = []
    for _ in range(m):
        a = int(input())
        mlis.append(a)
    ans = 1
    mae = -1

    for i in range(m):
        broken = mlis[i]
        if mae == broken - 1:
            print(0)
            exit()
        nobori = broken - 1 - (mae + 1)
        if nobori == 0:
            ans *= 1
            mae = broken
        else:
            ans *= fibona(nobori)
            ans %= (10 ** 9 + 7)
            #print(i, broken, nobori, ans) 
            mae = broken
    nobori = n - (mae+1)
    ans *= fibona(nobori) 
    ans %= (10 ** 9 + 7)
    print(int(ans))

        
        



if __name__ == "__main__":
    main()


### FIXED CODE ###

from itertools import product

def mat2_mul(X, Y):
	z = [[0, 0], [0, 0]]
	for (i, j, k) in product(range(2), range(2), range(2)):
		z[i][j] += X[i][k] * Y[k][j]
	return z

def mat2_pow(X, n):
	if n == 0:
		return [[1, 0], [0, 1]]
	elif n % 2:
		return mat2_mul(X, mat2_pow(X, n - 1))
	else:
		half_pow = mat2_pow(X, n / 2)
		return mat2_mul(half_pow, half_pow)

def fibona(n):
	if n == 0:
		return 0
	else:
		f = [[0, 1], [1, 1]]
	return mat2_pow(f, n - 1)[1][1]

def main():
    n, m = map(int,input().split())
    mlis = []
    for _ in range(m):
        a = int(input())
        mlis.append(a)
    ans = 1
    mae = 0

    infi = 10 ** 9 + 7
    for num in mlis:
        ans *= fibona(num-mae)
        ans %= infi
        mae = num + 1

    nobori = n - mae + 1
    ans *= fibona(nobori) 
    ans %= infi
    print(int(ans))
    



if __name__ == "__main__":
    main()
n = int(input())

sum = 0
for i in range(n):
  v,t = input().split()
  v = int(v)
  if t = 'BTC':
    sum+=v*38000
  else:
    sum+=v

print(sum)

### FIXED CODE ###

n = int(input())
 
sum = 0
for i in range(n):
  v,t = input().split()
  v = float(v)
  if t == 'BTC':
    sum+=v*380000
  else:
    sum+=v
    
print(sum)
N, K = map(int, input().split())

d = []
l = []
i = 0

while i <= 2*K:
  i += 1
  if i % 2 == 1:
    d.append(int(input()))
  else:
    l.append(list(map(int,input().split()))

L = set(l)
print(K - len(L))

### FIXED CODE ###

N, K = map(int, input().split())

d = []
l = []
i = 0

while i < 2*K:
  i += 1
  if i % 2 == 0:
    l.extend([int(x) for x in input().split()])
  else:
    d.append(int(input()))

L = list(set(l))
print(N - len(L))
from collections import defaultdict
s=list(input())
d=defaultdict(0)
for i in s:
  d[i]+=1
for i in d.values():
  if i%2:
    print("No")
    break
else:
  print("Yes")

### FIXED CODE ###

from collections import defaultdict
s=list(input())
d=defaultdict(int)
for i in s:
  d[i]+=1
for i in d.values():
  if i%2:
    print("No")
    break
else:
  print("Yes")
n, x = map(int, input().split())
l = 2 * n - 1

if x == 1 or x == l:
    print('No')
    exit(0)

ans = list(map(lambda k: (k - n + x) % l + 1, range(l)))
ans[n - 3], ans[n + 1] = ans[n + 1], ans[n - 3]
print('Yes')
print(' '.join(map(str, ans)))


### FIXED CODE ###

n, x = map(int, input().split())
l = 2 * n - 1

if x == 1 or x == l:
    print('No')
    exit(0)

if n == 2:
    print('Yes\n1\n2\n3')
    exit(0)

ans = list(map(lambda k: (k - n + x) % l + 1, range(l)))
ans[n - 3], ans[n + 1] = ans[n + 1], ans[n - 3]
print('Yes')
for v in ans:
    print(v)
number =list(map(int, input().split()))

if (1 <= number[0] <= 9) and (1 <= number[1] <= 9):
    print(a*b)
else:
    print(-1)

### FIXED CODE ###

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

if (1 <= number[0] <= 9) and (1 <= number[1] <= 9):
    print(number[0] * number[1])
else:
    print(-1)
n,k=map(int,input().split())
a=sorted(list(map(int,input().split())))
def groupby(src_list):
  dest_list=[[src_list[0],1]]
  for i in range(1,len(src_list)):
    if dest_list[-1][0]==src_list[i]:
      dest_list[-1][1]+=1
    else:
      dest_list.append([src_list[i],1])
  return dest_list
b=groupby(a)
b.sort(key=lambda x:x[1],reverse=True)
l=len(b)
ans=0
for i in range(k,l):
  ans+=b[i][1]
print(ans)

### FIXED CODE ###

st = input()
tl = 0
for s in st[:]:
  tl += int(s)
print(tl)
scores=[]
def depth(now,score,d):
    global scores
    if d[now]:
        for i in d[now]:
            depth(i,score+1,d)
        return 
    else:
        scores.append(score)
        return 


N,M=map(int,input().split())
d=[[] for i in range(N)]
for i in range(M):
    x,y=map(int,input().split())
    d[x-1].append(y-1)

Max=0
for i in range(N):
    depth(i,0,d)
    if scores and max(scores)>Max:
        Max=max(scores)
    scores=[]
print(Max)

### FIXED CODE ###

import numpy as np
import sys
sys.setrecursionlimit(100000)
N,M=map(int,input().split())
d=[[] for i in range(N)]
for i in range(M):
    x,y=map(int,input().split())
    d[x-1].append(y-1)
dp=[0 for i in range(N)]

def depth(now,score,d):
    global dp
    if dp[now]==0 or not(dp[now]):
        if d[now]:
            _score=[]
            for i in d[now]:
                _score.append(depth(i,score+1,d)-score)
            dp[now]=max(_score)
        else:
            return score

        return dp[now]+score

    else:
        return dp[now]+score



Max=0
for i in range(N):
    m=depth(i,0,d)
    if  m>Max:            
        Max=m
print(Max)
a, b =int(input().split())
if a*b % 2 == 1:
    print('Odd')
else:
    print('Even')


### FIXED CODE ###

a, b = map(int, input().split())
if a*b % 2 == 1:
    print("Odd")
else:
    print("Even")
import fractions
N = int(input())
A = list(map(int, input().split()))
AB = 1
for i in A:
    AB = (AB*i)//fractions.gcd(AB,i)
sumB = 0
for i in A:
    sumB += int(AB/i)
print(sumB%(10**9+7))

### FIXED CODE ###

import fractions
N = int(input())
A = list(map(int, input().split()))
AB = 1
for i in A:
    AB = AB*i//fractions.gcd(AB,i)
sumB = 0
for i in A:
    sumB += AB//i
print(int(sumB%(10**9+7)))
N = int(input())
H = list(map(int,input().split()))


getter = 0
def solver(now,count,to):
  global getter
  if now+1 < len(H) and H[now] >= H[now+1] and to != 2:
    solver(now+1,count+1,1)
  getter = max(getter,count)

for i in range(N):
  solver(i,0,0)

print(getter)


### FIXED CODE ###

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

cnt = 0
ret = 0
for i in range(N-1):
  if H[i] >= H[i+1]:
    cnt += 1
  else:
    ret = max(cnt,ret)
    cnt = 0
  if i == N-2:
    ret = max(cnt,ret)
print(ret)
import sys


def spam(ab, cd, count=0):
    ab = ab[:]
    cd = cd[:]
    for x in ab:
        for y in cd:
            if x[0] < y[0] and x[1] < y[1]:
                ab.remove(x)
                cd.remove(y)
                return spam(ab, cd, count + 1)
    return count


def main():
    N = int(sys.stdin.readline())
    ab = [[int(x) for x in sys.stdin.readline().split()] for _ in range(N)]
    cd = [[int(x) for x in sys.stdin.readline().split()] for _ in range(N)]
    ab1 = sorted(ab, key=lambda x: (x[0], x[1]))
    cd1 = sorted(cd, key=lambda x: (x[0], x[1]))
    ab2 = sorted(ab, key=lambda x: (x[1], x[0]))
    cd2 = sorted(cd, key=lambda x: (x[1], x[0]))
    print(max([spam(ab1, cd1), spam(ab2, cd2)]))


if __name__ == '__main__':
    main()


### FIXED CODE ###

import sys


def main():
    A, B, C = [int(x) for x in sys.stdin.readline().split()]
    if C <= A + B:
        print('Yes')
    else:
        print('No')


if __name__ == '__main__':
    main()
a = int().split()

b = l[0]+l[1]
c = l[1]+l[2]
d = l[2]+l[0]

e=list[]
e.append(b)
e.append(c)
e.append(d)

print(min(e))

### FIXED CODE ###

a = [int(i) for i in input().split()]
list=[]
S1 = a[0]+a[1]
S2 = a[1]+a[2]
S3 = a[2]+a[0]
list.append(S1)
list.append(S2)
list.append(S3)

print(min(list))
s=input()
if len(s)==26:
	d=[]
	for i in range(26):
		if list(s[-i-1:][::-1])!=sorted(s[-i-1:]):
			for j in range(i+1):
				d.append(s[-j-1])
			d.sort()
			if d[0]==s[-i-1]:
				k=d[1]
				print(2/0)
			else:
				k=d[0]
			print(s[:-i-1]+k)
			exit()
	print(-1)
	exit()
d=[0]*26
for i in range(len(s)):
	d[ord(s[i])-ord("a")]+=1
for i in range(26):
	if d[i]==0:
		x=chr(ord("a")+i)
		break
print(s+x)

### FIXED CODE ###

s=input()
if len(s)==26:
	d=[]
	for i in range(26):
		if list(s[-i-1:][::-1])!=sorted(s[-i-1:]):
			for j in range(i+1):
				d.append(s[-j-1])
			d.sort()
			if d[0]==s[-i-1]:
				k=d[1]
			else:
				for j in range(len(d)):
					if d[j]>s[-i-1]:
						k=d[j]
						break
			print(s[:-i-1]+k)
			exit()
	print(-1)
	exit()
d=[0]*26
for i in range(len(s)):
	d[ord(s[i])-ord("a")]+=1
for i in range(26):
	if d[i]==0:
		x=chr(ord("a")+i)
		break
print(s+x)
def insertionSort(A,n,g):
	cnt = 0
	for i in range(g,n):
		v = A[i]
		j = i - g
		while j >= 0 and A[j] > v:
			A[j+g] = A[j]
			j = j - g
			cnt += 1
		A[j+g] = v

def shellsort(A,n):
	cnt = 0
	h = 0
	while(h <= n / 9): h = 3*h + 1
	G = []
	while h > 0:
		G.append(h)
		h /= 3
	print("-----")
	print(len(G))

	print(" ".join(map(str,G)))
	for i in range(len(G)):
		insertionSort(A,n,G[i])
	for i in A:
		print(i)	
n = int(input())
A = []
for _ in range(n):
	A.append(int(input()))
shellsort(A,n)




### FIXED CODE ###

def insertionSort(A,n,g):
    cnt = 0
    for i in range(g,n):
        v = A[i]
        j = i - g
        while j >= 0 and A[j] > v:
            A[j+g] = A[j]
            j = j - g
            cnt += 1
            A[j+g] = v
    return cnt
    
def shellsort(A,n):
    cnt = 0
    h = 1
    G = []
    while h <= n:
        G.append(h)
        h = 3*h + 1
    G.reverse()
    m = len(G)
    print(m)

    print(" ".join(map(str,G)))
    for i in range(m):
        cnt += insertionSort(A,n,G[i])
    print(cnt)
    for i in A:
        print(i)
        
n = int(input())
A = []
for _ in range(n):
    A.append(int(input()))
shellsort(A,n)
from sys import stdin
N = int(stdin.readline().rstrip())
A = [int(_) for _ in stdin.readline().rstrip().split()]
ans = 1
for a in A:
    ans *= a
    if ans > 10**18:
        print(-1)
        return
print(ans)

### FIXED CODE ###

from sys import exit, stdin
N = int(stdin.readline().rstrip())
A = [int(_) for _ in stdin.readline().rstrip().split()]
ans = 1
if 0 in A:
    print(0)
    exit()
for a in A:
    ans *= a
    if ans > 10**18:
        print(-1)
        exit()
print(ans)
N,*D=map(int,open(0).read().split())
c=[0]*N
for i in D:c[i]+=1
if D[0]>0 or c[0]>1:print(0);exit()
a=1
for i in range(max(D)+1):a*=c[i]**c[i+1]
print(a)


### FIXED CODE ###

N,*D=map(int,open(0).read().split())
c=[0]*N
for i in D:c[i]+=1
m=max(D)
if D[0]>0 or c[0]>1:print(0);exit()
a=1
for i in range(m):a*=c[i]**c[i+1]
print(a%998244353)
a = raw_input()
[::-1]
print a

### FIXED CODE ###

a = raw_input()
a = a[::-1]
print a