Harryxun/stf_run huggingface dataset:
from sys import stdin
import sys
import math
from functools import reduce
import functools
import itertools
from collections import deque,Counter,defaultdict
from operator import mul
import copy
# ! /usr/bin/env python
# -*- coding: utf-8 -*-
import heapq
sys.setrecursionlimit(10**6)
# INF =  float("inf")
INF = 10**18
import bisect
import statistics
mod = 10**9+7
# mod = 998244353
import numpy

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

g = [0 for i in range(N)]

for i in range(Q):
    A = int(input())
    g[A-1] += 1

for i in range(N):
    if Q - g[i] >= K:
        print("No")
    else:
        print("Yes")



### FIXED CODE ###

from sys import stdin
import sys
import math
from functools import reduce
import functools
import itertools
from collections import deque,Counter,defaultdict
from operator import mul
import copy
# ! /usr/bin/env python
# -*- coding: utf-8 -*-
import heapq
sys.setrecursionlimit(10**6)
# INF =  float("inf")
INF = 10**18
import bisect
import statistics
mod = 10**9+7
# mod = 998244353

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

g = [0 for i in range(N)]

for i in range(Q):
    A = int(input())
    g[A-1] += 1

for i in range(N):
    if Q - g[i] >= K:
        print("No")
    else:
        print("Yes")
time_input = input()
time = time_input.split()

A = time[0]
B = time[1]

if A + B > 24:
    print(A + B - 24)
elif A + B == 24:
    print(0)
else:
    print(A + B)

### FIXED CODE ###

time_input = input()
time = time_input.split()

A = int(time[0])
B = int(time[1])

if A + B > 24:
    print(A + B - 24)
elif A + B == 24:
    print(0)
else:
    print(A + B)
n = int(input())
a_list = list(map(int, input().split()))
zero = a_list.count(0)
D = 1000000000 + 7
a_set = set(a_list)
if zero == 1 and n -1 == 2 * a_set:
    print(2 ** ((n-1)//2) % D)
elif zero == 0 and n == 2 * a_set:
    print(2 ** (n//2) % D)
else:
    print(0)

### FIXED CODE ###

n = int(input())
a_list = list(map(int, input().split()))
zero = a_list.count(0)
D = 1000000000 + 7
a_set = set(a_list)
if zero == 1 and n - 1 == 2 * (len(a_set)-1):
    print(2 ** ((n-1)//2) % D)
elif zero == 0 and n == 2 * len(a_set):
    print(2 ** (n//2) % D)
else:
    print(0)
a, b, c = map(int,input().split())
if c − a − b > 0 and 4 * a * b < (c − a − b)**2:
  print('Yes')
else:
  print('No')

### FIXED CODE ###

a, b, c = map(int,input().split())
if (c - a - b > 0) and (4 * a * b < (c - a - b)**2):
  print('Yes')
else:
  print('No')
num=1
while True:
    maxw=input()
    if maxw==0:break
    N=input()
    ws,ps=[0]*N,[0]*N
    for i in range(N):
        ps[i],ws[i]=map(int,raw_input().strip().split(","))
    #dp=[[0]*(maxw+1) for i in range(N+1)]
    ret=0
    for i in range(N):
        for j in range(maxw+1):
            if (j+ws[i])<=maxw:
                dp[i+1][j+ws[i]]=max(dp[i+1][j+ws[i]],dp[i][j]+ps[i])
                ret=max(dp[i+1][j+ws[i]],ret)
    print "Case %d:"%num
    print ret
    print dp[len(ws)].index(ret)
    num+=1

### FIXED CODE ###

num=1
while True:
    maxw=input()
    if maxw==0:break
    print "Case %d:"%num
    dp,w,v=[0]*1001,[0]*1001,[0]*1001
    n=input()
    for i in xrange(n):
        v[i],w[i]=map(int,raw_input().strip().split(","))
    for i in xrange(n):
        for j in xrange(maxw,-1,-1):
            if j+w[i]<=maxw:
                dp[j+w[i]]=max(dp[j+w[i]],dp[j]+v[i])
    print max(dp)
    print dp.index(max(dp))
    num+=1
def get_primes(n):
    max_p = int(n ** 0.5)
    p = 0 # 素数
    pl = []  # 素数リスト
    el = [i for i in range(2, n + 1)]  # 探索リスト
    while p <= max_p:
        nxt = []
        p = el[0]
        pl.append(p)
        for e in el:
            if e % p == 0:
                # D[e] = p
                pass
            else:
                nxt.append(e)
        el = nxt
    return pl


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

is_pc = True
is_sc = True

p_list = get_primes(N)
for p in p_list:
    t = [int(x % p == 0) for x in a]
    s = sum(t)
    if s >= 2:
        is_pc = False
    if s == N:
        is_sc = False
        break
if is_pc:
    print('pairwise coprime')
elif is_sc:
    print('setwise coprime')
else:
    print('not coprime')

### FIXED CODE ###

d, t, s = map(int, input().split())
a = d / s
if a <= t:
    print('Yes')
else:
    print('No')
n = int(input())
s = list(input())

rs = []
gs = []
bs = []

for i in range(n):
  if s[i] == "R":
    rs.append(i)
  elif s[i] == "G":
    gs.append(i)
  elif s[i] == "B":
    bs.append(i)

def binary(lst, d):
  low = 0
  high = len(lst) - 1
  while low <= high:
    mid = (low + high) // 2
    if lst[mid] == d:
      return True
    elif lst[mid] < d:
      low = mid + 1
    else:
      high = mid - 1
  return False

ans = len(rs)*len(gs)*len(bs)
for i in range(len(rs)):
  for j in range(len(gs)):
    dis = abs(rs[i] - gs[j])
    if (rs[i] + gs[j])%2 == 0:
      can1 = abs(rs[i] + gs[j])//2
      if binary(bs, can1):
      	ans -= 1
    if max(rs[i], gs[j]) + dis <= bs[-1]:
      can2 = max(rs[i], gs[j]) + dis
      if binary(bs, can2):
      	ans -= 1
    if min(rs[i], gs[j]) - dis >= 0:
      can3 = min(rs[i], gs[j]) - dis
      if binary(bs, can3):
      	ans -= 1
        
print(ans)

### FIXED CODE ###

import sys

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

rs = []
gs = []
bs = []

for i in range(n):
  if s[i] == "R":
    rs.append(i)
  elif s[i] == "G":
    gs.append(i)
  elif s[i] == "B":
    bs.append(i)

def binary(lst, d):
  low = 0
  high = len(lst) - 1
  while low <= high:
    mid = (low + high) // 2
    if lst[mid] == d:
      return True
    elif lst[mid] < d:
      low = mid + 1
    else:
      high = mid - 1
  return False

ans = len(rs)*len(gs)*len(bs)
if len(bs) == 0:
  print(0)
  sys.exit()
for i in range(len(rs)):
  for j in range(len(gs)):
    dis = abs(rs[i] - gs[j])
    if (rs[i] + gs[j])%2 == 0:
      can1 = abs(rs[i] + gs[j])//2
      if binary(bs, can1):
      	ans -= 1
    if max(rs[i], gs[j]) + dis <= bs[-1]:
      can2 = max(rs[i], gs[j]) + dis
      if binary(bs, can2):
      	ans -= 1
    if min(rs[i], gs[j]) - dis > 0:
      can3 = min(rs[i], gs[j]) - dis
      if binary(bs, can3):
      	ans -= 1
        
print(ans)
a, b, c, d = [int(e) for e in input().split()]

def gcd(a, b):
  while True:
    t = b % a
    if t == 0:
      return a
    b, a = a, t

def f(a, b, n):
  x = (a // n) * n
  if x < a:
    x += n
  if x > b:
    return 0
  result = 0
  if a <= x <= b:
    result += 1
  result += (b - x) // n
  return result

acc = 0
acc += f(a, b, c)
acc += f(a, b, d)
acc -= f(a, b, gcd(c * d))
print(b - a + 1 - acc)


### FIXED CODE ###

a, b, c, d = [int(e) for e in input().split()]

def gcd(a, b):
  while True:
    t = b % a
    if t == 0:
      return a
    b, a = a, t

def f(a, b, n):
  x = (a // n) * n
  if x < a:
    x += n
  if x > b:
    return 0
  result = 0
  if a <= x <= b:
    result += 1
  result += (b - x) // n
  return result

acc = 0
acc += f(a, b, c)
acc += f(a, b, d)
acc -= f(a, b, c * d // gcd(c, d))
print(b - a + 1 - acc)
n,r = int(input().split())
if n<10:
	r = 100*(10-n)
print(r)


### FIXED CODE ###

n,r = map(int,input().split())
if n<10:
	r = 100*(10-n)+r
print(r)
N = int(input())
S = lisr(input())
cnt = 0
for i in range(1, N-1):
    if S[i-1] == "#":
        for j in range(i, N-1):
             if S[j] ==  ".":
                 cnt += 1
print(cnt)

### FIXED CODE ###

A, B, C = map(int, input().split())
if A > B:
    tmp = A
    A =  B
    B = tmp 

if C >= A and C <= B:
    print("Yes")
else:
    print("No")
def combinations(N, K):
    N = int(N)
    K = int(K)
    k_ex = K
    n_ex = N
    n_k_ex = N - K
    for i in range(1, K):
        k_ex *= i
    for i in range(1, N):
        n_ex *= i
    for i in range(1, N - K):
        n_k_ex *= i
    return int(n_ex / (k_ex * n_k_ex))
N, K = input().split(' ')

print(combinations(N, K))

### FIXED CODE ###

def combinations(N, K):
    N = int(N)
    K = int(K)
    if N == K:
        return 1
    else:
        return N - K + 1
    
N, K = input().split(' ')

print(combinations(N, K))
K=int(input())
S=list(input())

if (len(S)+1) <= K:
    print(S)
elif (len(S)+1) > K:
    print(S[0:(SL-1):1],"...")


### FIXED CODE ###

K=int(input())
S=input()
s=list(S)

if len(s) <= K:
    print(S)
else:
    print(S[0:K:]+"...")
N, R = int(input())

if N >= 10: print(K)
else: print(100*(10-K))

### FIXED CODE ###

N, R = map(int, input().split())
 
if N >= 10: print(R)
else: print(R + 100*(10-N))
import math
import random

def computeGCD(x, y):
    if x > y:
        small = y
    else:
        small = x
    for i in range(1, small + 1):
        if ((x % i == 0) and (y % i == 0)):
            gcd = i

    return gcd


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

tmpgcd = list()
for i in range(2):
    sample = random.choices(a, k=2)
    tmpgcd.append(computeGCD(sample[0], sample[1]))

# print('hey')

tmpgcd = sorted(tmpgcd)
mini = tmpgcd[1]
# print(mini, tmpgcd)
result = 0
for i in range(mini, -1, -1):
    tmp = [x % i for x in a]
    tmp = [x for x in tmp if x != 0]
    if len(tmp) <= 1:
        result = i
        break

print(result)

### FIXED CODE ###

def gcd(a, b):
    if a < b:
        a, b = b, a
    if b == 0:
        return a
    c = a % b
    return gcd(b, c)


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

l = [0]*(n+2)
r = [0]*(n+2)
m = [0]*(n+2)

for i in range(n+1):
    j = n-i
    if i == 0:  # j = n
        l[i] = 0
        r[j+1] = 0
    else:
        l[i] = gcd(l[i-1], a[i-1])
        r[j] = gcd(r[j+1], a[j])

m = [gcd(l[i], r[i+1]) for i in range(n+1)]

print(max(m))
inputA =  list(map(int,input().split()))
inputB =  list(map(int,input().split()))

humancount = inputA[0]
talllimit = inputA[1]
count= 0

for count in range(0,humancount):
    if inputB(count) >= talllimit:
        count += 1


print(count)

### FIXED CODE ###


inputA =  list(map(int,input().split()))
inputB =  list(map(int,input().split()))

humancount = inputA[0]
talllimit = inputA[1]
anser = 0

for count in range(0,humancount):
    if inputB[count] >= talllimit:
        anser += 1


print(anser)
n = int(input())
stop = int(sqrt(n)) + 1
min_count = 10 ** 100
for a in range(1, stop):
    if n % a != 0:
        continue
    else:
        b = n // a
    count = a + b - 2
    if count < min_count:
        min_count = count
print(min_count)

### FIXED CODE ###

from math import sqrt
n = int(input())
stop = int(sqrt(n)) + 1
min_count = 10 ** 100
for a in range(1, stop):
    if n % a != 0:
        continue
    else:
        b = n // a
    count = a + b - 2
    if count < min_count:
        min_count = count
print(min_count)
def get_answer(s):
    count = 0
    for i, c in enumerate(s):
        if i == len(s) - 1:
            return count
        if c == "A" and s[i + 1] == "C":
            count += 1

    return count

n, q = map(int, input().split())
s = str(input())
questions = []
for i in range(q):
    a, b = map(int, input().split())
    questions.append((a - 1, b - 1))

for question in questions:
    print(get_answer(s[question[0]: question[1] + 1]))


### FIXED CODE ###

map = {
    "A":"T",
    "T":"A",
    "C":"G",
    "G":"C"
}

a = str(input())
print(map[a])
#!/usr/bin/env python3
inf = float('inf')

ans = True
def dfs(s):
    global ans
    for t, d in G[s]:
        if x[t] == inf:
            x[t] = x[s] + d
            dfs(t)
        else:
            if x[t] - x[s] != d:
                ans = False

N, M = map(int, input().split())
x = [inf] * N
G = [[] for _ in range(N)]
for i in range(M):
    L, R, D = map(int, input().split())
    L -= 1
    R -= 1
    G[L].append([R, D])
    G[R].append([L, -D])
for i in range(N):
    if x[i] == inf:
        x[i] = 0
        dfs(i)
print(('No', 'Yes')[ans])


### FIXED CODE ###

#!/usr/bin/env python3
import sys
sys.setrecursionlimit(200002)

def dfs(s):
    for t, d in G[s]:
        if x[t] is None:
            x[t] = x[s] + d
            if not dfs(t):
                return False
        else:
            if x[t] - x[s] != d:
                return False
    return True

N, M = map(int, input().split())
x = [None] * N
G = [[] for _ in range(N)]
for i in range(M):
    L, R, D = map(int, input().split())
    L -= 1
    R -= 1
    G[L].append([R, D])
    G[R].append([L, -D])
ans = True
for i in range(N):
    if x[i] is None:
        x[i] = 0
        if not dfs(i):
            ans = False
print(('No', 'Yes')[ans])
import numpy as np

def main():
    num, weigh = map(int, input().split())
    dp = np.zeros((num + 1, weigh + 1), dtype=int)

    for i in range(1, num + 1):
        now_weigh, now_value = map(int, input().split())
        dp[i, :now_weigh] = dp[i - 1, :now_weigh]
        dp[i, now_weigh:] = np.maximum(dp[i - 1, :weigh - now_weigh + 1] + now_value, dp[i - 1, now_weigh:])

    print(dp[-1][-1])


if __name__ == '__main__':
    main()



### FIXED CODE ###

from collections import Counter, defaultdict
import sys
sys.setrecursionlimit(10 ** 5 + 10)
input = sys.stdin.readline
from math import factorial
import heapq, bisect
import math
import itertools
import numpy as np




def main():
    num, lim_weight = map(int, input().split())
    data = [list(map(int, input().split())) for i in range(num)]

    dp = np.full(10 ** 5 + 1, np.inf)

    for i in range(num):
        weight, value = data[i]
        prev = dp.copy()
        dp[:value] = np.minimum(prev[:value], weight)
        dp[value:] = np.minimum(prev[value:], prev[:-value] + weight)

        # print(dp[:100])
    ans = np.max(np.where(dp <= lim_weight)) + 1
    print(ans)

if __name__ == '__main__':
    main()
N = input()
A = int(input())
B = int(input())

if N == 1:
  print('Hello World')
else:
  print(A + B)
  

### FIXED CODE ###

N = int(input())
 
if N == 1:
  print('Hello World')
else:
  A = int(input())
  B = int(input())
  print(A + B)
import datetime

t = datetime.datetime.strptime(input(), "%Y/%m/%d")
if t < (year=2019, month=5, day=1):
    print("Heisei")
else:
  	print("TBD")


### FIXED CODE ###

import datetime
 
t = datetime.datetime.strptime(input(), "%Y/%m/%d")
if t < datetime.datetime(year=2019, month=5, day=1):
    print("Heisei")
else:
    print("TBD")
n, m = map(int, input().split())
r = [1]
mod = 1000000007
a = [int(input())]

for i in range(n):
  if i == a[-1] - 1:
    if len(a) < m:
      a.append(int(input()))
    r.append(0)
  elif i == 0:
    r.append(1)
  else:
    r.append((r[i] + r[i-1]) % mod)
print(r[-1])

### FIXED CODE ###

n, m = map(int, input().split())
r = [0, 1]
mod = 1000000007
a = []
for i in range(m):
  a.append(int(input()))
j = 0
for i in range(n):
  if j < m and i == a[j] - 1:
    r = [r[1], 0]
    j += 1
  else:
    r = [r[1], (r[0] + r[1]) % mod]
print(r[-1])
# 2019-11-28 02:28:10(JST)
import sys

def gcd(a, b):
    while b:
        a, b = b, a % b
    return a

def lcm(a, b):
    return a * b // gcd(a, b)

def main():
    n, m = map(int, sys.stdin.readline().split())
    s, t = sys.stdin.read().split()

    g = gcd(n, m)
    l = lcm(n, m)

    if g == 1:
        if s[0] == s[1]:
            ans = l
        else:
            an = -1
    else:
        for i in range(g):
            if s[i * n // g] == t[i * m // g]:
                continue
            else:
                ans = -1
                break
        else:
            ans = l
    
    print(ans)

if __name__ == '__main__':
    main()


### FIXED CODE ###

# 2019-11-28 02:28:10(JST)
import sys

def gcd(a, b):
    while b:
        a, b = b, a % b
    return a

def lcm(a, b):
    return a * b // gcd(a, b)

def main():
    n, m = map(int, sys.stdin.readline().split())
    s, t = sys.stdin.read().split()

    g = gcd(n, m)
    l = lcm(n, m)

    if g == 1:
        if s[0] == t[0]:
            ans = l
        else:
            ans = -1
    else:
        for i in range(g):
            if s[i * n // g] == t[i * m // g]:
                continue
            else:
                ans = -1
                break
        else:
            ans = l
    
    print(ans)

if __name__ == '__main__':
    main()
a, b = map(int, raw_input().split())

 if a < b:
  print 'a < b' 
 elif a > b:
  print 'a > b'
 elif a == b:
  print 'a == b'

### FIXED CODE ###

a, b = map(int, raw_input().split())
 
if a < b:
 print "a < b"
elif a > b:
 print "a > b"
elif a == b:
 print "a == b"
import math 
n=int(input())
n =math.factorial(n)
m = (10**9) + 7
if n < m:
    prtint(n)
else :
    print(n%m)

### FIXED CODE ###

import math 
n=int(input())
n =math.factorial(n)
m = (10**9) + 7
print(n%m)
a, b, n = map(int, input().split())
val = (a*n)//b - a*(n//b)
val = max(val, (a*m)//b - a*(m//b))
print(val)

### FIXED CODE ###

a, b, n = map(int, input().split())
val = (a*n)//b - a*(n//b)
m = max(0,(n//b)*b-1)
val = max(val, (a*m)//b - a*(m//b))
print(val)
import math
gcd = math.gcd
# from fractions import gcd


MOD = 10**9+7

N = int(input())
A = list(map(int,input().split()))
#%%
def modinv(x,mod):
    return pow(x,mod-2,mod)

B = []
for a in A:
    b = modinv(a,MOD)
    B.append(b)

def lcm(a,b):
    return a//gcd(a,b)*b

ans = 0

cur = 1
for a in A:
    cur =  lcm(cur,a)
for b in B:
    ans += cur*b
ans %= MOD
print(ans)



### FIXED CODE ###


from fractions import gcd


MOD = 10**9+7

N = int(input())
A = list(map(int,input().split()))
#%%
def modinv(x,mod):
    return pow(x,mod-2,mod)

B = []
for a in A:
    b = modinv(a,MOD)
    B.append(b)

def lcm(a,b):
    return a//gcd(a,b)*b

ans = 0

cur = 1
for a in A:
    cur =  lcm(cur,a)
for b in B:
    ans += cur*b
ans %= MOD
print(ans)
#ITP1_10-D Distance2
n = int(input())
x = float().split(" ")
y = float().split(" ")

d1=0.0
for i in range(n):
    d1 += abs(x[i]-y[i])
print(d1)

d2=0.0
for i in range(n):
    d2 += (x[i]-y[i])**2
print(d2**0.5)

d3=0.0
for i in range(n):
    d3 += (x[i]-y[i])**3
print(d3**(1.0/3.0))

d_inf=0.0
for i in range(n):
    if abs(x[i]-y[i])>d_inf:
        d_inf = x[i]-y[i]
print(d_inf)

### FIXED CODE ###

#ITP1_10-D Distance2
n = int(input())
x = [float(x) for x in input().split(" ")]
y = [float(x) for x in input().split(" ")]

d1=0.0
for i in range(n):
    d1 += abs(x[i]-y[i])
print(d1)

d2=0.0
for i in range(n):
    d2 += (x[i]-y[i])**2
print(d2**(1/2))

d3=0.0
for i in range(n):
    d3 += abs((x[i]-y[i])**3)
print(d3**(1/3))

d_inf=0.0
for i in range(n):
    if abs(x[i]-y[i])>d_inf:
        d_inf = abs(x[i]-y[i])
print(d_inf)
#172C

N,M,K=map(int,input().split())
A=list(map(int,input().split()))
B=list(map(int,input().split()))
ans=0

if K>=sum(A)+sum(B):
    print(N+M)
    exit()
elif K<min(A[0],B[0]):
    print(0)
    exit()
else:
    for i in range(N):
        sum_a=sum(A[:i+1])
        a=A
        b=B
        m=0
        while K>sum_a+b[0] and len(b)>=1:
            sum_a+=b[0]
            b.pop(0)
            m+=1
        if i+1+m>ans:
            ans=i+1+m
print(ans)

### FIXED CODE ###

#172C
#Tsundoku

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

a,b=[0],[0]

for i in range(N):
    a.append(a[i]+A[i])
for j in range(M):
    b.append(b[j]+B[j])

ans=0
j=M

for i in range(N+1):
    if a[i]>K:
        break
    while a[i]+b[j]>K:
        j-=1
    ans=max(ans,i+j)
print(ans)
import re
S=str(input())
k=int(input())
x=re.search(r'[2-9]',S).start()

if S[0]=='1':
  if k<=x:
    print(S[0])
  else:
    print(S[x])     
  
else:
  print(S[0])


### FIXED CODE ###

import re
S=str(input())
k=int(input())

if set(S)=={'1'}:
  print(1)
  
else:
  x=re.search(r'[2-9]',S).start()
      
  if S[0]=='1':
    if k<=x:
      print(S[0])
    else:
      print(S[x])     
  else:
    print(S[0])
s,w=map(int,input.split())


if s>w:
    print(safe)
else:
    print(unsafe)

### FIXED CODE ###


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


if s>w:
    print("safe")
else:
    print("unsafe")
N, M = map(int,input().split())
S = [0] * M
for i in range(N):
  A = list(map(int, input().split()))[1:]
  for j in A:
    S[j]=S[j]+1
for y in S:
  if y == N:
    print(y)

### FIXED CODE ###

N, M = map(int,input().split())
S = [0] * M
for i in range(N):
  A = list(map(int, input().split()))[1:]
  for j in A:
    S[j-1]+=1

count = 0
for y in S:
  if y == N:
    count+=1

print(count)
N, K = map(int, input().split())
L = list(map(int, input().split()))
dp = [-1 for k in range(K+1)]
# dp[0] = 1
def fn(n):
	if dp[n] != -1:
		return dp[n]
	if n == 0:
		dp[n] = 0
		return dp[n]
	ans = 0
	for i in L:
		if fn(n-i) == 0:
			ans = 1
			break
	dp[n] = ans		
	return dp[n]
for l in range(K):
	fn(l)
if fn(K):
	print("First")
else:
	print("Second")

### FIXED CODE ###

N, K = map(int, input().split())
L = list(map(int, input().split()))
dp = [-1 for k in range(K+1)]
# dp[0] = 1
def fn(n):
	if dp[n] != -1:
		return dp[n]
	if n == 0:
		dp[n] = 0
		return dp[n]
	ans = 0
	for i in L:
		if n >= i:
			if fn(n-i) == 0:
				ans = 1
				break
	dp[n] = ans		
	return dp[n]
for l in range(K):
	fn(l)
if fn(K) == 1:
	print("First")
else:
	print("Second")
D, N =  map(int,input().split())
if D == 0:
    li = [int(i) for i in range(1,100)]
    print(li[N-1])
if D == 1:
    li = [int(i) for i in range(int(100),int(1e4),int(100))]
    print(li[N-1])
if D == 2:
    li = [int(i) for i in range(int(1e4),int(1e9),int(1e4))]
    print(li[N-1])
   

### FIXED CODE ###

D, N = map(int, input().split())
print(100 ** D * (N + N // 100))
a = input()
print(a ** 3)

### FIXED CODE ###

a = int(input())
print(a ** 3)
X, Y = map(int, input().split())

def gcd(x, y):
  if y == 0:
    return x
  else:
    return gcd(y, x%y)

g = Y / gcd(X, Y)

if g == 1:
  print("-1")
else:
  if g == 2:
    g = 3
  else:
    g = 2
  ans = X * g
  if ans <= 1e18:
	print(ans)
  else:
    print("-1")

### FIXED CODE ###

X, Y = map(int, input().split())

def gcd(x, y):
  if y == 0:
    return x
  else:
    return gcd(y, x%y)

g = Y / gcd(X, Y)

if g == 1:
  print("-1")
else:
  if g == 2:
    g = 3
  else:
    g = 2
  ans = X * g
  if ans <= 1e18:
    print(ans)
  else:
    print("-1")
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 7)
import bisect
import numpy as np

num = 0
for x in range(K+1):
    tmp = min(S-x, K) - max(0, S-K-x)
    if tmp >= 0:
        num += tmp + 1


print(num)

### FIXED CODE ###

K, S = map(int, input().split())
number = 0
for x in range(K+1):
  for y in range(K+1):
    z = S - (x + y)
    if 0 <= z <= K:
      number += 1
print(number)
[N,K]=list(map(int, input().split()))
h=list(map(int, input().split()))
K=min(N,K)
 
dp=[[0 for i in range(K+1)] for j in range(N)]
 
for i in range (1,K):
    for j in range (0,i):
        dp[i][j]=dp[i-j-1][K]+abs(h[i-j-1]-h[i])
        dp[i][K]=min(dp[i][0:j+1])
 
for i in range (K,N):
    for j in range (0,K):
        dp[i][j]=dp[i-j-1][K]+abs(h[i-j-1]-h[i])
        dp[i][K]=min(dp[i][0:K])
 
print(dp[N-1][K])

### FIXED CODE ###

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

dp=[]
dp.append(0)
dp.append(abs(h[0]-h[1]))

for i in range (2,N):
    dp.append(min(dp[i-2]+abs(h[i]-h[i-2]),dp[i-1]+abs(h[i]-h[i-1])))

print(dp[N-1])
n , k = list(map(int, input().split()))
kaijou = []
kaijou.append(1)
kaijou.append(1)
i = 2
while(i <= n):
    kaijou.append(i * kaijou[i - 1])
    i += 1
for i in range(1, k+1):
    b = (kaijou[k - 1] / (kaijou[i - 1] * kaijou[k - i]))
    a = (kaijou[n - k + 1] /  (kaijou[i] * kaijou[n - k + 1 - i]))
    print(int(a * b) % 1000000007)

### FIXED CODE ###

import numpy as np
import math

n , k = list(map(int, input().split()))
def combi(a,b):
    return  math.factorial(a) // (math.factorial(b) * math.factorial(a-b))
i = 2
mod = 10 ** 9 + 7
for i in range(1, k + 1):
    if n - k + 1 >= i and k - 1 >= i - 1:
        print(int(combi(n - k + 1,i) * combi(k - 1, i - 1) % mod))
    else:
        print(0)
a = int(input())
b = int(input())
h = int(input())

print(2(a+b)*h)

### FIXED CODE ###

a = int(input())
b = int(input())
h = int(input())

print(int((a+b)*h/2))
l=list(map(int,input().split()))
s=sum(l)
if(l<=21):
  print("win")
else:
  print("bust")

### FIXED CODE ###

l=list(map(int,input().split()))
s=sum(l)
if(s<=21):
  print("win")
else:
  print("bust")