Harryxun/stf_run huggingface dataset:
N = int(input())
A = [int(a) for a in input().split()]


def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)
    return divisors


divisor = []
for i in range(1, N + 1):
    divisor.append(make_divisors(i))
B = [0]*N
rs = [0]*N
for i in range(N - 1, -1, -1):
    if rs[i] != A[i]:
        B[i] = 1
        for j in divisor[i]:
            rs[j] = 1 - rs[j]

print(sum(B))
for i in range(N):
    if B[i] == 1:
        print(i+1)

### FIXED CODE ###

N = int(input())
A = [int(a) for a in input().split()]


def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)
    return divisors


divisor = []
for i in range(1, N + 1):
    divisor.append(make_divisors(i))
B = [0]*N
rs = [0]*N
for i in range(N - 1, -1, -1):
    if rs[i] != A[i]:
        B[i] = 1
        for j in divisor[i]:
            rs[j-1] = 1 - rs[j-1]

print(sum(B))
for i in range(N):
    if B[i] == 1:
        print(i+1)
n,m = map(int, input().split())
sc = [list(map(int, input().split())) for i in range(m)]
keta = ["-1"] * n
if n == 1:
  ans = -1
  for s,c in sc:
    if ans == -1 or ans == c:
      ans = c
    else:
      print(-1)
      exit()
  if ans == -1:
    print(0)
  else:
    print(ans)
else:
  for s,c in sc:
    s-=1
    if keta[s] == "-1" or keta[s] == str(c):
      keta[s] = str(c)
    else:
      print(-1)
      exit()
  ans = ""
  for k,i in enumerate(keta):
    if i == "-1":
      if k == 0:
        ans += "1"
      else:
        ans += "0"
    else:
      ans += i   
  if ans[0] == "0":
    print(-1)
    exit()
  else:
    print(ans)


### FIXED CODE ###

n = int(input())
if n % 2:
  print(n//2+1)
else:
  print(n//2)
import math
a,b=map(int,input().split())
c=math.gcd(a,b)
print((a*b)//c)


### FIXED CODE ###

import fractions
a,b=map(int,input().split())
c=fractions.gcd(a,b)
print((a*b)//c)
import sys
sys.setrecursionlimit(10**6)
N,M,K = map(int,input().split())
fri = [[] for i in range(N+1)] #iさんの友達
for i in range(M):
    a,b = map(int,input().split())
    fri[a].append(b)
    fri[b].append(a)
bro = [[] for i in range(N+1)] #iさんのブロック
for i in range(K):
    c,d = map(int,input().split())
    bro[c].append(d)
    bro[d].append(c)

def dfs(i):
    seen[i] = True
    size_is[cur] += 1
    n_is[i] = cur
    for a in fri[i]:
        if not seen[a]: dfs(a)

seen = [False]*(N+1)
n_is = [0]*(N+1)
size_is = [0]
cur = 0
for i in range(1,N+1):
    if not seen[a]: #Falseで入る
        cur += 1
        size_is.append(0)
        dfs(i)

ans = [0]*N
for a in range(1,N+1):
    ans[a-1] = size_is[n_is[a]]-1
    for b in fri[a]:
        if n_is[b] == n_is[a]: ans[a-1] -= 1
    for d in bro[a]:
        if n_is[d] == n_is[a]: ans[a-1] -= 1

ans = list(map(str, ans))
print(" ".join(ans))

### FIXED CODE ###

def find(x): #xの根を求める
    if par[x] < 0:
        return x
    else:
        par[x] = find(par[x])
        return par[x]

def unite(x,y): #xとyの属する集合の併合
    x = find(x)
    y = find(y)
    
    if x == y:
        return False
    else:
        #sizeの大きいほうがx
        if par[x] > par[y]:
            x,y = y,x
        par[x] += par[y]
        par[y] = x
        return True

def same(x,y): #xとyが同じ集合に属するかの判定
    return find(x) == find(y)

def size(x): #xが属する集合の個数
    return -par[find(x)]

N,M,K = map(int, input().split())
par = [-1]*(N+1)
fri = [[] for i in range(N+1)]
for i in range(M):
    a,b = map(int,input().split())
    fri[a].append(b)
    fri[b].append(a)
    unite(a,b)

bro = [[] for i in range(N+1)]
for i in range(K):
    c,d = map(int,input().split())
    bro[c].append(d)
    bro[d].append(c)

ans = [0]*N
for i in range(1,N+1):
    ans[i-1] = size(i)-1
    for f in fri[i]:
        if same(f,i): ans[i-1] -= 1
    for b in bro[i]:
        if same(b,i): ans[i-1] -= 1

# print(par)
ans = list(map(str,ans))
print(" ".join(ans))
n,l = map(int, input().split())
L = [0]*n
#l+i-1
for i in range(n):
  L[i] += l+i

if(l < 0 and n + l < 0):
  print(sum(L) - L[n-1])
elif(l =< 0 and n + l >= 0):
  print(sum(L))
else:
  print(sum(L) - L[0])


### FIXED CODE ###

n , l = map(int, input().split())
L = []

for i in range(n):
    L.append(i+l)

if L[0] > 0:
    print(sum(L[1:]))
elif L[0] <=0 and L[-1] >= 0:
    print(sum(L))
else:
    print(sum(L[:-1]))
import numpy as np
H, W, D=list(map(int,input().split(" ")))
#print(in1)
#arr=np.zeros((in1[0],in1[1]))
d={}
for i in range(H):
    #arr[i]=input().split(" ")
    for n,k in enumerate(input().split(" ")):
        d[int(k)]=[i,n]
#print(arr)
Q=int(input())
out=[]

cost={}
for i in range(1,D+1):
    now = i + D
    cost[i]=abs(d[now][0] - d[now - D][0]) + abs(d[now][1] - d[now - D][1])
    while now <= H * W:
        cost[now] = cost[now - D] + abs(d[now][0] - d[now - D][0]) + abs(d[now][1] - d[now - D][1])
        now += D


out=[]
for k in range(Q):
    start,end=list(map(int,input().split(" ")))
    out.append(cost[end]-cost[start])

for i in out:
    print(int(i))


### FIXED CODE ###

import numpy as np
H, W, D=list(map(int,input().split(" ")))
#print(in1)
#arr=np.zeros((in1[0],in1[1]))
d={}
for i in range(H):
    #arr[i]=input().split(" ")
    for n,k in enumerate(input().split(" ")):
        d[int(k)]=[i,n]
#print(arr)
Q=int(input())
out=[]

cost={}

for i in range(1,D+1):
    now = i + D
    cost[i]=0
    #cost[i]=abs(d[now][0] - d[now - D][0]) + abs(d[now][1] - d[now - D][1])
    while now <= H * W:
        cost[now] = cost[now - D] + abs(d[now][0] - d[now - D][0]) + abs(d[now][1] - d[now - D][1])
        now += D


out=[]
for k in range(Q):
    start,end=list(map(int,input().split(" ")))
    out.append(cost[end]-cost[start])

for i in out:
    print(int(i))
x1,y1,x2,y2 = [int(s) for s in input().split(' ')]

print(((x1-x2)**2 + (y1-y2)**2)**0.5)

### FIXED CODE ###

x1,y1,x2,y2 = [float(s) for s in input().split(' ')]

print(((x1-x2)**2 + (y1-y2)**2)**0.5)
import sys
input = sys.stdin.readline


def read():
    H, W = map(int, input().strip().split())
    S = []
    for i in range(H):
        s = list(input().strip())
        S.append(s)
    return H, W, S


def solve(H, W, S):
    dd = [(1, 0), (0, 1), (-1, 0), (0, -1)]

    def dfs(y, x):
        depth = 0
        S[y][x] = "."
        for dy, dx in dd:
            ny = y + dy
            nx = x + dx
            if 0 <= ny < H and 0 <= nx < W and S[ny][nx] == "#":
                depth = max(depth, dfs(ny, nx) + 1)
        return depth

    for i in range(H):
        for j in range(W):
            depth = dfs(i, j)
            if depth == 1:
                return "No"
    return "Yes"


if __name__ == '__main__':
    inputs = read()
    outputs = solve(*inputs)
    if outputs is not None:
        print("%s" % str(outputs))


### FIXED CODE ###

import sys
input = sys.stdin.readline
sys.setrecursionlimit(200000)


def read():
    H, W = map(int, input().strip().split())
    S = []
    for i in range(H):
        s = list(input().strip())
        S.append(s)
    return H, W, S


def solve(H, W, S):
    if H == 1 and  W == 1 and S[0][0] == "#":
        return "No"
    
    dd = [(1, 0), (0, 1), (-1, 0), (0, -1)]

    def dfs(y, x):
        depth = 1
        S[y][x] = "."
        for dy, dx in dd:
            ny = y + dy
            nx = x + dx
            if 0 <= ny < H and 0 <= nx < W and S[ny][nx] == "#":
                depth = max(depth, dfs(ny, nx) + 1)
        return depth

    for i in range(H):
        for j in range(W):
            if S[i][j] == "#":
                depth = dfs(i, j)
                if depth == 1:
                    return "No"
    return "Yes"


if __name__ == '__main__':
    inputs = read()
    outputs = solve(*inputs)
    if outputs is not None:
        print("%s" % str(outputs))
n = int(input())
if n >= 30
  print("Yes")
  else:
    print("No")
    

    
 
  

### FIXED CODE ###

n = int(input())

if 30 <= n <= 40:
  print('Yes')
else:
  print('No')
N, M = [int(x) for x in input().split()]

A = [None]*N
for i in range(N):
    A[i] = input()

B = [None]*M
for i in range(M):
    B[i] = input()

def check():
    for x in range(N-M+1):
        for y in range(N-M+1):
            if all(all(A[r+x][c+y] == B[r][c] for c in range(M)) for r range(M))
                return "Yes"
    return "No"
print(check())



### FIXED CODE ###

N, M = [int(x) for x in input().split()]

A = [None]*N
for i in range(N):
    A[i] = input()

B = [None]*M
for i in range(M):
    B[i] = input()

def check():
    for x in range(N-M+1):
        for y in range(N-M+1):
            match = True
            for r in range(M):
                if not all(A[r+x][c+y] == B[r][c] for c in range(M)):
                    match = False
                    break
            if match:
                return "Yes"

    return "No"
print(check())
x=0
s_max = 0

n = int(input())
s = input()

for i in s:
    if i == "I":
        x += 1
    else:
        x -= 1
    x_max = max(x_max,x)

print(x_max)

### FIXED CODE ###

x=0
x_max = 0

n = int(input())
s = input()

for i in s:
    if i == "I":
        x += 1
    else:
        x -= 1
    x_max = max(x_max,x)

print(x_max)
T=list(input())
T2=(T.replace('?', 'd'))

print(T2)

### FIXED CODE ###

T=input()
T2=(T.replace('?', 'D'))

print(T2)
N = int(input())
L = list(map(int, input().split()))
 
ans = 0
for i in range(N):
  for j in range(i+1, N):
    for k in range(j+1, N):
      if(L[i] != L[j] and L[i] != L[k] and L[j] != L[k] and abs(L[j]-L[k]) < L[i] and L[i] < L[j]+L[k]): t.append((L[i], L[j], L[k])):
          ans +=1
          
print(ans)

### FIXED CODE ###

N = int(input())
L = list(map(int, input().split()))
 
ans = 0
if(N >= 3):
  t = []
  for i in range(N):
    for j in range(i+1, N):
      for k in range(j+1, N):
        if((L[i] != L[j]) & (L[i] != L[k]) & (L[j] != L[k]) & (abs(L[j]-L[k]) < L[i]) & (L[i] < L[j]+L[k])): t.append((L[i], L[j], L[k]))
  ans = len(t)

print(ans)
l = ["a","b","c","d","e"]
c = input()

if c in l:
    print("vowel")
else:
    prin("consonant")


### FIXED CODE ###


l = ["a","e","i","o","u"]
c = input()

if c in l:
    print("vowel")
else:
    print("consonant")
s=input()
n=int(s)
ss=0
for i in len(s):
  ss+=int(s[i])
if n%ss=0:
  print("Yes")
else:
  print("No")
 

### FIXED CODE ###

s=input()
n=int(s)
ss=0
for i in range(len(s)):
  ss+=int(s[i])
if n%ss==0:
  print("Yes")
else:
  print("No")
import math
def lcm(x, y):
    return (x * y) // math.gcd(x, y)

def main():
    
    a,b = map(int, input().split())
    
    print(lcm(a, b))

if __name__ == '__main__':
    main()



### FIXED CODE ###

import fractions

def lcm(x, y):
    return (x * y) // fractions.gcd(x, y)

def main():
    
    a,b = map(int, input().split())
    
    ans = lcm(a,b)
    print(ans)

if __name__ == '__main__':
    main()
n, k = map(int, input().split())
A = []
for _ in range(n):
    t, d = map(int, input().split())
    A.append((d, t))
A.sort(reverse=True)
X = []
Y = []
st = set()
for d, t in A:
    if t in st:
        X.append(d)
    else:
        Y.append(d)
    st.add(t)
ans = 0
len_x = len(X)
len_y = len(Y)
if len_y >= k:
    a = 0
    b = len_y - 1
    x = 0
    y = sum(Y[:k])
else:
    a = k - len_y
    b = len_y - 1
    x = sum(X[:k - len_y])
    y = sum(Y)
ans = x + y + len_y ** 2
t = ans
for i in range(min(len_x, len_y, k)):
    x += X[a]
    a += 1
    y -= Y[b]
    b -= 1
    len_y -= 1
    t = x + y + len_y ** 2
    ans = max(ans, t)
print(ans)


### FIXED CODE ###

n, k = map(int, input().split())
A = []
for _ in range(n):
    t, d = map(int, input().split())
    A.append((d, t))
A.sort(reverse=True)
X = []
Y = []
st = set()
for i in range(k):
    d, t = A[i]
    if t in st:
        X.append(d)
    else:
        Y.append(d)
        st.add(t)
x = sum(X)
y = sum(Y)
v = len(Y)
ans = x + y + v ** 2
for i in range(k, n):
    if not X:
        break
    d, t = A[i]
    if t in st:
        continue
    st.add(t)
    x -= X.pop()
    y += d
    v += 1
    ans = max(ans, x + y + v ** 2)
print(ans)
k,t=map(int,input().split())
a=[int(i) for i in input().split()]

a=sorted(a,reverse=True)

while True:
	if a[1]==0:
		ans=max(a[0]-1,0)
		break
	a[0]-=1
	a[1]-=1
	a=sorted(a,reverse=True)
print(ans)

### FIXED CODE ###

k,t=map(int,input().split())
a=[int(i) for i in input().split()]

a=sorted(a,reverse=True)

if len(a)==1:
	ans=a[0]-1

else:
	while True:
		if a[1]==0:
			ans=max(a[0]-1,0)
			break
		a[0]-=1
		a[1]-=1
		a=sorted(a,reverse=True)
print(ans)
n,m = [int(x) for x in input().split()]
sc = {}
out = False
for _ in range(m):
    s,c = [x for x in input().split()]
    if s in sc.keys():
        if sc[s] != c:
            print("-1")
            out = True
        else:
            sc[s] = c
    else:
        sc[s] = c
        

if not out:
    if n == 1:
        print(sc["1"])
    elif n == 2:
        if not "1" in sc.keys():
            sc["1"] = "1"
            if not "2" in sc.keys():
                sc["2"] = "0"
            print(sc["1"],sc["2"],sep="")
        else:
            if sc["1"] == "0":
                print("-1")
            else:
                if not "2" in sc.keys():
                    sc["2"] = "0"
                print(sc["1"],sc["2"],sep="")
    elif n == 3:
        if not "1" in sc.keys():
            sc["1"] = "1"
            if not "2" in sc.keys():
                sc["2"] = "0"
            if not "3" in sc.keys():
                sc["3"] = "0"
            print(sc["1"],sc["2"],sc["3"],sep="")
        else:
            if sc["1"] == "0":
                print("-1")
            else:
                if not "2" in sc.keys():
                    sc["2"] = "0"
                if not "3" in sc.keys():
                    sc["3"] = "0"
                print(sc["1"],sc["2"],sc["3"],sep="")

### FIXED CODE ###

n,m = [int(x) for x in input().split()]
sc = {}
out = False
for _ in range(m):
    s,c = [x for x in input().split()]
    if s in sc.keys():
        if sc[s] != c:
            print("-1")
            out = True
        else:
            sc[s] = c
    else:
        sc[s] = c
        

if not out:
    if n == 1:
        if not "1" in sc.keys():
            sc["1"] = "0"
        print(sc["1"])
    elif n == 2:
        if not "1" in sc.keys():
            sc["1"] = "1"
            if not "2" in sc.keys():
                sc["2"] = "0"
            print(sc["1"],sc["2"],sep="")
        else:
            if sc["1"] == "0":
                print("-1")
            else:
                if not "2" in sc.keys():
                    sc["2"] = "0"
                print(sc["1"],sc["2"],sep="")
    elif n == 3:
        if not "1" in sc.keys():
            sc["1"] = "1"
            if not "2" in sc.keys():
                sc["2"] = "0"
            if not "3" in sc.keys():
                sc["3"] = "0"
            print(sc["1"],sc["2"],sc["3"],sep="")
        else:
            if sc["1"] == "0":
                print("-1")
            else:
                if not "2" in sc.keys():
                    sc["2"] = "0"
                if not "3" in sc.keys():
                    sc["3"] = "0"
                print(sc["1"],sc["2"],sc["3"],sep="")
def LI(): return list(map(int, input().split()))
    def LS(): return input().split()
    def I(): return int(input())
    def S(): return input()
     
    n, m = LI()
    a = LI()
    d = dict([(i, [i])for i in range(n)])
    for i in range(m):
        x, y = LI()
        d[x].append(y)
        d[y].append(x)
     
            
    pow = [1]*n
     
    def mori(num, mori_list):
        for c in d[num]:
            if pow[c] == 1:
                mori_list.append(a[c])
                pow[c] = 0
                mori(c, mori_list)
     
    zen_mori = []
    for i in range(n):
        if pow[i] == 1:
            mori_list = []
            mori(i, mori_list)
            zen_mori.append(sorted(mori_list)[::-1])
     
     
    l = len(zen_mori)
    check_list = [0]*l
     
    if n - l < l - 2:
        print("Impossible")
        exit()
     
    ans = 0
    for cnt in range(l-1):
        pos = 0
        one, two = 0, 0
        use = []
        while True:
            min_list = [[zen_mori[i][-1] if len(zen_mori[i]) > 0 else (10**9 + 1), i] for i in range(l)]
            use = sorted(min_list)
            one, two = use[pos][1], use[pos+1][1]
            if check_list[one] == 1 and check_list[two] == 1:
                pos += 1
                continue
            if len(zen_mori[one]) == 1 and len(zen_mori[two]) == 1:
                pos += 1
                continue
            break
        ans += use[pos][0] + use[pos+1][0]
        try:
            zen_mori[one].pop()
        except:
            pass
        try:
            zen_mori[two].pop()
        except:
            pass
        check_list[one] = 1
        check_list[two] = 1
    print(ans)

### FIXED CODE ###

from collections import defaultdict
from heapq import heappop, heappush
n,m = map(int, input().split())
a = list(map(int, input().split()))

uf = [-1]*n
def root(x):
    if uf[x] < 0:
        return x
    uf[x] = root(uf[x])
    return uf[x]
def unite(x,y):
    rx, ry = root(x), root(y)
    if rx == ry:
        return False
    if uf[rx] > uf[ry]:
        rx, ry = ry, rx
    uf[rx] += uf[ry]
    uf[ry] = rx
    return True

for i in range(m):
    x,y = map(int, input().split())
    unite(x,y)
if m == n-1:
    print(0)
elif (n-m-1)*2 > n:
    print("Impossible")
else:
    d = defaultdict(list)
    for i in range(n):
        heappush(d[root(i)], a[i])
    cnt = (n-m-1)*2
    ans = 0
    heap = []
    for value in d.values():
        ans += heappop(value)
        cnt -= 1
        while value:
            heappush(heap, heappop(value))
    for _ in range(cnt):
        ans += heappop(heap)
    print(ans)
N , M = map(int, input().split())
As =[input() for _ in range(N)]
Bs =[input() for _ in range(M)]
m = N-M
for i in range(m):
    for j in range(m):
        flag = True
        for k in range(i, M+i):
            for l in range(j, M+j):
                if As[k][l] != Bs[k-i][l-j]:
                    flag = False
                    break
            if not flag:
                break
        if flag:
            break
    if flag:
        break
if flag:
    print('Yes')
else:
    print('No')
            
        

### FIXED CODE ###

N , M = map(int, input().split())
As =[input() for _ in range(N)]
Bs =[input() for _ in range(M)]
m = N-M
for i in range(m+1):
    for j in range(m+1):
        flag = True
        for k in range(M):
            for l in range(M):
                if As[k+i][l+j] != Bs[k][l]:
                    flag = False
                    break
            if not flag:
                break
        if flag:
            break
    if flag:
        break
if flag:
    print('Yes')
else:
    print('No')
import sys
readline = sys.stdin.readline

N = int(readline())
X = readline().rstrip()

X0 = int(X, 2)
count1 = X.count("1")

X0mod0to1 = X0 % (count1 + 1) # 0->1に変化した際の、X0を割った余り
X0mod1to0 = X0 % (count1 - 1) # 1->0に変化した際の、X0を割った余り

from collections import defaultdict
dp = defaultdict(int)
dp[0] = 0
def f(x): # 愚直にf(x)を求める式
  temp = x
  if x in dp:
    return dp[x]
  cnt = 0
  while x != 0:
    cnt += 1
    pc = bin(x).count("1")
    x %= pc
  dp[temp] = cnt
  return cnt

val = 1
ans = [-1] * N

for i in range(N - 1, -1, -1): # 下の桁から順に、f(Xi)の値を求める
  if X[i] == "0": # 0を1に変える場合
    pat = (X0mod0to1 + val % (count1 + 1)) % (count1 + 1)
    ans[i] = f(pat) + 1
  elif X[i] == "1": # 1を0に変える場合
    pat = (X0mod1to0 - val % (count1 - 1)) % (count1 - 1)
    ans[i] = f(pat) + 1
  val *= 2

print(*ans, sep = "\n")

### FIXED CODE ###

import sys
readline = sys.stdin.readline

N = int(readline())
X = readline().rstrip()

X0 = int(X, 2)
count1 = X.count("1")

X0mod0to1 = X0 % (count1 + 1) # 0->1に変化した際の、X0を割った余り
if count1 > 1:
  X0mod1to0 = X0 % (count1 - 1) # 1->0に変化した際の、X0を割った余り
else:
  X0mod1to0 = 0

from collections import defaultdict
dp = defaultdict(int)
dp[0] = 0
def f(x): # 愚直にf(x)を求める式
  if x in dp:
    return dp[x]
  pc = bin(x).count("1")
  val = f(x % pc) + 1
  dp[x] = val
  return val
  
val0to1 = 1
val1to0 = 1
ans = [-1] * N

for i in range(N - 1, -1, -1): # 下の桁から順に、f(Xi)の値を求める
  if X[i] == "0": # 0を1に変える場合
    pat = (X0mod0to1 + val0to1 % (count1 + 1)) % (count1 + 1)
    ans[i] = f(pat) + 1
  elif X[i] == "1": # 1を0に変える場合
    if count1 > 1:
      pat = (X0mod1to0 - val1to0 % (count1 - 1)) % (count1 - 1)
      ans[i] = f(pat) + 1
    else:
      ans[i] = 0
  val0to1 = val0to1 * 2 % (count1 + 1)
  if count1 != 1:
    val1to0 = val1to0 * 2 % (count1 - 1)

print(*ans, sep = "\n")
a,b,c,d,e,f=map(int,input().split())
w=set([])
for i in range(31):
    for j in range(31):
        x=a*i*100+b*j*100
        if x<=f:
            w.add(x)
s=set([])
for i in range(3001):
    for j in range(3001):
        y=c*i+d*j
        if y<=f:
            s.add(y)
tmpn=0
for i in w:
    for j in s:
        if i+j<=f and i//100*e>=j:
            if tmpn<j/(1.0*(i+j)):
                tmpn=j/(1.0*(i+j))
                ans=[i,j]
print(*ans)

### FIXED CODE ###

a,b,c,d,e,f=map(int,input().split())
w=set([])
for i in range(31):
    for j in range(31):
        x=a*i*100+b*j*100
        if 0<x<=f:
            w.add(x)
s=set([])
for i in range(3001):
    for j in range(3001):
        y=c*i+d*j
        if y<=f:
            s.add(y)
tmpn=-1
ans=[0,0]
for i in w:
    for j in s:
        if i+j<=f and i//100*e>=j:
            if tmpn<j/(1.0*(i+j)):
                tmpn=j/(1.0*(i+j))
                ans=[i+j,j]
print(*ans)
orint(x ** 3)

### FIXED CODE ###

x = int(input())
print( x ** 3)
N=int(input())

ans=0
while(True):
   ans+=111
  if(ans>=N):
    print(ans)
    break
  

### FIXED CODE ###

N=int(input())
 
ans=0

while(True):
  ans+=111
  if(ans>=N):
    print(ans)
    break
_, _, M = map(int, input().split())
# price list
a_list = list(map(int, input().split()))
b_list = list(map(int, input().split()))
# min price
min_price = min(a_list) + min(b_list)
for _ in range(M):
  x, y, c = map(int, input().split())
  discount_price = a_list[x] + b_list[y] - c
  if discount_price < min_price:
    min_price = discount_price
print(min_price)

### FIXED CODE ###

_, _, M = map(int, input().split())
# price list
a_list = list(map(int, input().split()))
b_list = list(map(int, input().split()))
# min price
min_price = min(a_list) + min(b_list)
for _ in range(M):
  x, y, c = map(int, input().split())
  discount_price = a_list[x-1] + b_list[y-1] - c
  min_price = min(min_price, discount_price)
print(min_price)
a, b, c = map(int, input().split())
print(min(c, b//a)

### FIXED CODE ###

a,b,c=map(int,input().split())
d=b//a
if d<=c:
  print(d)
else:
  print(c)
def main():
	l = map(int, input().split())
	A=l[0]
	B=l[1]
	C=l[2]

	l_max=max(A,B,C)
	l_min=min(A,B,C)
	l_mid=(A+B+C)-(l_max+l_min)

	ans=10*l_max+l_mid+l_min
	print(ans)
    
main()

### FIXED CODE ###

def main():
	A, B, C = [int(_) for _ in input().split()]

	l_max=max(A,B,C)
	l_min=min(A,B,C)
	l_mid=(A+B+C)-(l_max+l_min)

	ans=10*l_max+l_mid+l_min
	print(ans)
    
main()