Harryxun/stf_run huggingface dataset:
from collections import Counter
n=int(input())
ab=list(map(int,input().split()))
M=max(ab)
a=[]
for i in Counter(ab):
  if Counter(ab)[i]==1:
    a.append(i)
ans=set([])
a.sort()
ans_count=0
N=0
if len(a)==0:
  print(0)
else:
  for i in range(n):
    if not a[i] in ans:
      N=a[i]
      count=1
      ans.add(N)
      ans_count+=1
      for j in range(2*N,M+1,N):
        ans.add(j)
  print(ans_count)

### FIXED CODE ###

from collections import Counter
n = int(input())
a = [int(v) for v in input().split()]
 
M = max(a)
d = [1 for i in range(M+1)]
for v in sorted(a):
    for j in range(2*v, M+1, v):
        d[j] = 0
ans = 0
c = Counter(a)
for i in a:
    if c[i]==1:
      ans += d[i]
print(ans)
n,a,b,c = map(int, input().split())
s = [input() for _ in range(n)]

d = {'A':a,'B':b,'C':c}

ans = ['Yes']

for i in range(n):
    if d[s[i][0]] == 0 and d[s[i][1]] == 0:
        print('No')
        exit()
    if d[s[i][0]] == 1 and d[s[i][1]] == 1 and n > 1:
        d[s[i][0]] = 2
        d[s[i][1]] = 0
        if d[s[i+1][0]] == 0 and d[s[i+1][1]] ==0:
            d[s[i][0]] = 0
            d[s[i][1]] = 2
            ans.append(s[i][1])
        else:
            ans.append(s[i][0])
    elif d[s[i][0]] >= d[s[i][1]]:
        d[s[i][0]] = d[s[i][0]] - 1
        d[s[i][1]] = d[s[i][1]] + 1
        ans.append(s[i][1])
    else:
        d[s[i][0]] = d[s[i][0]] + 1
        d[s[i][1]] = d[s[i][1]] - 1
        ans.append(s[i][0])

for i in range(n+1):
    print(ans[i])

### FIXED CODE ###

n,a,b,c = map(int, input().split())
s = [input() for _ in range(n)]

d = {'A':a,'B':b,'C':c}

ans = ['Yes']

for i in range(n):
    if d[s[i][0]] == 0 and d[s[i][1]] == 0:
        print('No')
        exit()
    if d[s[i][0]] == 1 and d[s[i][1]] == 1 and n-i > 1:
        d[s[i][0]] = 2
        d[s[i][1]] = 0
        if d[s[i+1][0]] == 0 and d[s[i+1][1]] ==0:
            d[s[i][0]] = 0
            d[s[i][1]] = 2
            ans.append(s[i][1])
        else:
            ans.append(s[i][0])
    elif d[s[i][0]] >= d[s[i][1]]:
        d[s[i][0]] = d[s[i][0]] - 1
        d[s[i][1]] = d[s[i][1]] + 1
        ans.append(s[i][1])
    else:
        d[s[i][0]] = d[s[i][0]] + 1
        d[s[i][1]] = d[s[i][1]] - 1
        ans.append(s[i][0])

for i in range(n+1):
    print(ans[i])
n=int(input())
C=list(map(int, input().split()))
c=set(C)
if len(c)==4:
  print('Four')
else:
  print('Three')

### FIXED CODE ###

n=int(input())
C=list(map(str, input().split()))
c=set(C)
if len(c)==4:
  print('Four')
else:
  print('Three')
N, C = map(int, input().split())
T = [[0 for k in range(100000)] for k in range(C)]

for k in range(N):
    s, t, c = map(int, input().split())
    T[c-1][s-1] += 1
    T[c-1][t] -= 1
for l in range(C):
    for k in range(1,100000):
        T[l][k] += T[l][k-1]

ans = 0
for k in range(100000):
    t = 0
    for l in range(C):
        if T[l][k]:
            t += 1
    ans = max(ans, t)

print(ans)


### FIXED CODE ###

N, C = map(int, input().split())
T = [[0 for k in range(100001)] for l in range(C)]

for k in range(N):
    s, t, c = map(int, input().split())
    T[c-1][s-1] += 1
    T[c-1][t] -= 1
for l in range(C):
    for k in range(1,100001):
        T[l][k] += T[l][k-1]

ans = 0
for k in range(100001):
    t = 0
    for l in range(C):
        if T[l][k] >= 1:
            t += 1
    ans = max(ans, t)

print(ans)
n = int(input())
List = []
List.append(int(input()))
List.append(int(input()))
List.append(int(input()))
List.append(int(input()))
List.append(int(input()))

#import math
print(math.ceil(n/min(List))+4)

### FIXED CODE ###

n = int(input())
List = []
List.append(int(input()))
List.append(int(input()))
List.append(int(input()))
List.append(int(input()))
List.append(int(input()))

import math
print(math.ceil(n/min(List))+4)
from fractions import gcd
#from math import gcd
#import numpy as np

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

lcms=[A[0]]
[lcms.append(s*lcms[-1]//gcd(lcms[-1], s)) for s in A]

ans=sum([(lcms[-1]//s) %(1e9+7) for s in A])%(1e9+7)

print(int(ans))

### FIXED CODE ###

from fractions import gcd
#from math import gcd
import numpy as np
import sys
input = sys.stdin.readline
mod = 10**9+7

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

lcm = 1
for s in A:
    lcm = s*lcm//gcd(lcm, s)

ans = lcm*sum([pow(s, mod-2, mod) for s in A]) % mod
#ans = sum([lcm//s % mod for s in A]) % mod

print(int(ans%mod))
DEVISOR = 2019

L, R = (int(word) for word in input().split())

if R // DEVISOR > L // DEVISOR:
    print(0)

L %= DEVISOR
R %= DEVISOR

print(min(i * j % DEVISOR for i in range(L, R) for j in range(i+1, R+1)))


### FIXED CODE ###

DEVISOR = 2019

L, R = (int(word) for word in input().split())

if (R // DEVISOR) > (L // DEVISOR):
    print(0)
    exit()

L %= DEVISOR
R %= DEVISOR

print(min(i * j % DEVISOR for i in range(L, R) for j in range(i+1, R+1)))
a, v = list(map(int, input("").split()))
b, w = list(map(int, input("").split()))
t = int(input(""))

l  = abs(a-b)

if (v - w) * t >= l:
    Print("YES")
else:
    Print("NO")

### FIXED CODE ###

a, v = list(map(int, input().split()))
b, w = list(map(int, input().split()))
t = int(input())

l  = abs(a-b)

if (v - w) * t >= l:
    print("YES")
else:
    print("NO")
N = int(input())
S = input()
def Zalgo(S):
    N = len(S)
    A = [0]*N
    A[0] = N
    i = 1
    j = 0
    while i < N:
        while i + j < N and S[j] == S[i + j]:
            j += 1
        A[i] = j
        if j == 0:
            i += 1
            continue
        k = 1
        while i + k < N and k + A[k] < j:
            A[i + k] = A[k]
            k += 1
        i += k
        j -= k
res = 0
for i in range(N - 1):
    lcp = Zalgo(S[i:])
    for j in range(N - i):
        l = min(j, lcp[j])
        res = max(l, res)
print(res)

### FIXED CODE ###

N = int(input())
S = input()
r = 1
ans = 0
for i in range(N):
    while True:
        if S.rfind(S[i : r + 1]) >= r + 1:
            r += 1
            ans = max(ans, r - i)
        else:
            break
print(ans)
import math
from functools import reduce
def lcm_base(x, y):
    return (x * y) // math.gcd(x, y)
def lcm_list(numbers):
    return reduce(lcm_base, numbers, 1)
N=int(input())
huga = list(map(int, input().split()))
X=lcm_list(huga)
sum1=0
for i in range (N):
    sum1+=(X/huga[i])%(10**9+7)
print(int(sum1))

### FIXED CODE ###

n=int(input())
A=list(map(int,input().split()))
mod=10**9+7
def lcm(X,Y):
    x=X
    y=Y
    if y>x:
        x,y=y,x
    while x%y!=0:
        x,y=y,x%y
    return X*Y//y

cnt=0
ans=0
LCM=1
for i in range(n):
    Q=lcm(LCM,A[i])
    cnt*=Q//LCM
    LCM=Q
    cnt+=Q//A[i]
print(cnt%mod)
#!/usr/bin/env python3
#ABC128 E

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

n,q = LI()
stx = [LI() for _ in range(n)]
stx.sort(key = itemgetter(2))
d = [I() for _ in range(q)]
ans = [-1]*q
right = [0]*q
for s,t,x in stx:
    l,r = bl(d,s-x),bl(d,t-x)
    #l≦d<rを満たすdがxでぶつかる
    #各dにおいて一番最初にぶつかるxを求めたい
    while l < r:
        while ans[l] != -1:
            l = right[l]
        if r <= l:
            break
        ans[l] = x
        right[l] = r
for i in ans:
    print(i)


### FIXED CODE ###

#!/usr/bin/env python3
#ABC128 E

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

n,q = LI()
stx = [LI() for _ in range(n)]
stx.sort(key = itemgetter(2))
d = [I() for _ in range(q)]
ans = [-1]*(q+1)
right = [0]*q
for s,t,x in stx:
    l,r = bl(d,s-x),bl(d,t-x)
    #l≦d<rを満たすdがxでぶつかる
    #各dにおいて一番最初にぶつかるxを求めたい
    while l < r:
        while ans[l] != -1:
            l = right[l]
        if r <= l:
            break
        ans[l] = x
        right[l] = r
        l += 1
for i in ans[:-1]:
    print(i)
s = input().split()
if s[0] == s[1] and s[1] == s[2]:
  print('No')
else:
  print('Yes')


### FIXED CODE ###

s = input()
if s[0] == s[1] and s[1] == s[2]:
  print('No')
else:
  print('Yes')
N = int(input())
H = list(map(int, input().split()))
ans = 0

while max(H) > 0:
    grp = [[]]
    for i, h in enumerate(H):
        if h == 0:
            if len(grp[-1]) > 0:
                grp.append([])
        else:
            grp[-1].append((i, h))
    for g in grp:
        mi = min([h for _, h in g])
        ans += mi
        for i, _ in g:
            H[i] -= mi

print(ans)


### FIXED CODE ###

from collections import deque

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

stack = deque([])
prevPoint = -1

for i in range(N) :
    if h[i] == 0 :
        stack.append((prevPoint+1 , i))
        prevPoint = i
    elif i >= N - 1 :
        stack.append((prevPoint+1,N))

ans = 0

while stack :
    start , end = stack.pop()

    if start >= end :
        ans += h[start]
        h[start] = 0
        continue


    minus = min(h[start:end])
    ans += minus

    prevPoint = start - 1
    for i in range(start,end) :
        h[i] -= minus
        if h[i] == 0 :
            stack.append((prevPoint+1,i))
            prevPoint = i
        elif i >= end - 1 :
            stack.append((prevPoint+1,end))

print(ans)
K,N = list(map(int,input().split()))
A = list(map(int,input().split()))

middle = K // 2

i=0
while A[i] <= middle:
  i += 1

d0 = A[i] - A[i-1]
d1 = K - A[-1] + A[0]

if d0 >= d1: print(K - d0)
else: print(K-d1)


### FIXED CODE ###

word = input()
if word[2]==word[3] and word[4]==word[5]:
  print ("Yes")
else:
  print("No")
N = int(input())
list=[]
for i in range(N):
    s, p = input().split()
    list.append([s, int(p)])
A=list
list.sort(key=lambda, list:(list[0], -list[1]))
for i in A:
    print(list.index(i)+1)

### FIXED CODE ###

N = int(input())
list=[]
for i in range(N):
    s, p = input().split()
    list.append([s, int(p), i+1])
list.sort(key=lambda list:(list[0], -list[1]))
for i in list:
    print(i[2])
n=int(input())
result = 0
for i in range(n):
  a = n-i
  while True:
    if a % 2 == 1:
      break
    else:
      if a == 2:
        print(n-i)
        sys.exit()
      else:
        a /= 2


### FIXED CODE ###

import sys

n=int(input())
if n==1:
  print(1)
  sys.exit()
result = 0
for i in range(n):
  a = n-i
  while True:
    if a % 2 == 1:
      break
    else:
      if a == 2:
        print(n-i)
        sys.exit()
      else:
        a /= 2
import heapq
import math
import random
import sys
from bisect import bisect_left, bisect_right
from collections import Counter, defaultdict, deque, namedtuple, UserDict
from functools import cmp_to_key, lru_cache, reduce
from itertools import (chain, combinations, combinations_with_replacement,
                       permutations, product)

sys.setrecursionlimit(10**6+1)
write = sys.stdout.write
# input = sys.stdin.buffer.readline

MOD = 10**9 + 7
INT_MAX = (1 << 63) - 1

@lru_cache(None)
def dfs(i, j, nums):
    if i == 1:
        return int(nums[j-1])
    return abs(dfs(i-1, j, nums) - dfs(i-1, j+1, nums))

if __name__ == "__main__":
    n = int(input())
    nums = input()
    print(dfs(n, 1, nums))



### FIXED CODE ###


def twos_in_factorial(n):
    return n - bin(n).count('1')


def parity_of_nCr(n, i):
    """ if odd, return False. """
    f = twos_in_factorial
    return f(n) - f(n-i) - f(i) > 0


if __name__ == "__main__":
    n = int(input())
    nums = list(map(lambda x: int(x) - 1, input().strip()))
    no_one = False
    if 1 not in nums:
        nums = [num // 2 for num in nums]
        no_one = True

    is_odd = False
    for i, num in enumerate(nums):
        if not parity_of_nCr(n-1, i) and num & 1:
            is_odd ^= 1

    if not is_odd:
        print(0)
    else:
        print(1 << no_one)
import math

N = int(input())
a = [int(i) for i in input().split()]
b = math.round(sum(a)/N)

c = sum([(i - b)**2 for i in a])
print(c)

### FIXED CODE ###

import math

N = int(input())
a = [int(i) for i in input().split()]
b = round(sum(a)/N)

c = sum([(i - b)**2 for i in a])
print(c)
import math

r = float(input())

print (r * r * math.PI), (2 * r * math.PI)

### FIXED CODE ###

import math

r = float(input())

print "{:.6f} {:.6f}".format((r * r * math.pi), (2 * r * math.pi))
X = int(input())
pleasure += (X // 500) * 1000
X //= 500
pleasure += (X // 5) * 5
print(pleasure)

### FIXED CODE ###

X = int(input())
pleasure = (X // 500) * 1000
X %= 500
pleasure += (X // 5) * 5
print(pleasure)
A = map(int, input().split())
total = A[0] + A[1]
if total >= 10:
	print('error')
else:
	print(total)

### FIXED CODE ###

a=eval(input().replace(" ","+"))
print(["error",a][a<10])
from collections import Counter as co
from itertools import combinations as com
from operator import mul
from functools import reduce

def combinations_count(n, r):
    r = min(r, n - r)
    numer = reduce(mul, range(n, n - r, -1), 1)
    denom = reduce(mul, range(1, r + 1), 1)
    return numer // denom

n=int(input())
a=0
l=co([set(co(input())) for i in range(n)])
for d,s in l.items():
  if s>=2:a+=combinations_count(s, 2)
print(a)

### FIXED CODE ###

from collections import Counter as co
from operator import mul
from functools import reduce

def combinations_count(n, r):
  r = min(r, n - r)
  numer = reduce(mul, range(n, n - r, -1), 1)
  denom = reduce(mul, range(1, r + 1), 1)
  return numer//denom


n=int(input())
a=0
l=[''.join(list(map(str,sum(sorted(list(map(list,co(input()).items()))),[])))) for i in range(n)]
for d,s in co(l).items():
  if s>=2:a+=combinations_count(s, 2)
print(a)
N = int(input())
s = list(map(int, input().split())
new_s = sorted(s)
count = 0

for i in range(N):
    if s[i]-new_s[i]!=0:
        count += 1

if count>2:
    print('NO')
else:
    print('YES')

### FIXED CODE ###

N = int(input())
s = list(map(int, input().split()))
new_s = sorted(s)
count = 0

for i in range(N):
    if s[i]-new_s[i]!=0:
        count += 1

if count>2:
    print('NO')
else:
    print('YES')
a = int(input())
f = False
for i in range(1,10):
    if a % i == 0 and a/i < 10:
        f = True
        break
if f:
    print "Yes"
else:
    print "No"

### FIXED CODE ###

n = int(input())

for i in range(1,10):
    for j in range(1, 10):
        if i * j == n:
            print("Yes")
            exit()
print("No")
N = int(input())
A = list(map(int,input().split()))

A.sort()
ans = A[-1]
count = 1
tmp_count = 1
j = -2
for i in range(N):
    ans += A[j]
    count += 1
    tmp_count +=1
    if count == 2:
        count = 0
        j -= 1
    if tmp_count == N-1:
        break
        
print(ans)
        
    

### FIXED CODE ###

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

A.sort(reverse = True)
ans = 0

from collections import deque
tmp = deque([A[0]])

for x in A[1:]:
    ans += tmp.popleft()
    tmp.append(x)
    tmp.append(x)
    
print(ans)
N=int(input())
A=list(map(int,input().split()))
key=max(A)+1 #最大値もrange(a,key,a)で計算させるため
B=[0]*key #0~Aの最大値までのlistを作成
for a in A:
    for b in range(a,key,a):
    B[b]+=1 #aの倍数を全てにBリストで1を足す
ans=0
for a in A:
    if B[a]==1: #自身しか倍数にならなかった物
    ans+=1
print(ans)

### FIXED CODE ###

N=int(input())
A=list(map(int,input().split()))
key=max(A)+1 #最大値もrange(a,key,a)で計算させるため
B=[0]*key #0~Aの最大値までのlistを作成
for a in A:
    for b in range(a,key,a):
        B[b]+=1 #aの倍数を全てにBリストで1を足す
ans=0
for a in A:
    if B[a]==1: #自身しか倍数にならなかった物
        ans+=1
print(ans)
n,m=map(int,input().split())
a=[int(input()) for _ in range(m)]
dp=[0]*(n+1)
for i in range(m):
    dp[n-a[i]]=-1
if dp[1]==0:
    dp[1]=1
else:
    dp[1]=0
if dp[2]==0:
    dp[2]=dp[1]+1
else:
    dp[2]=0
if n>=3:
    for i in range(3,n+1):
        if dp[i]==0:
            dp[i]=dp[i-1]+dp[i-2]
        else:
            dp[i]=0
print(dp[n]%1000000007)

### FIXED CODE ###

n,m=map(int,input().split())
a=[int(input()) for _ in range(m)]
dp=[0]*(n+1)
for i in range(m):
    dp[n-a[i]]=-1
if dp[1]==0:
    dp[1]=1
else:
    dp[1]=0
if n>1:
    if dp[2]==0:
        dp[2]=dp[1]+1
    else:
        dp[2]=0
if n>=3:
    for i in range(3,n+1):
        if dp[i]==0:
            dp[i]=dp[i-1]+dp[i-2]
        else:
            dp[i]=0
print(dp[n]%1000000007)
n, a, b = map(int, input().split())
t = 'b' * a + 'r' * b
count = int(n/len(t)) + 1 
t=(t*count)[0:n]
print(t.count('r'))

### FIXED CODE ###

n, a, b = map(int, input().split())
t = a + b
count = t if t > 0 else 0
r = 0
if count == 0:
	r = 0
else:
	d = int(n/t)
	if d*t == n:
		r = d * a
	else:
		r = d * a
		e = n - d*t
		if e <= a:
			r = r + e
		else:
			r = r + a
print(r)
n = int(input())
input_num = input().split(" ")
sort_list = sorted(input_num)
center = int(n/2) - 1
for num in input_num:
    new_list = sort_list[0:]
    new_list.remove(num)
    print(new_list[center])

### FIXED CODE ###

input_data = input().split(" ")
a, b, x = int(input_data[0]), int(input_data[1]), int(input_data[2])
def check(A, B, X):
    if (A > X) or (A+B < X):
        return print("NO")
    inb_cat = X - A
    if inb_cat > B:
        return print("NO")

    else:
        return print("YES")


check(a, b, x)
n = int(input())
l = [input() for i in range(n)]
for i in range(3):
    m = max(l)
    a.remove(m)
    print (m)


### FIXED CODE ###

import sys
e = [int(i) for i in sys.stdin.readlines()]
for i in range(3):
    m = max(e)
    e.remove(m)
    print (m)
K=int(input())
A=int(input())
B=int(input())
if A>=1 and B<=1000:
  print('OK')
else:
  print('NG')

### FIXED CODE ###

k = int(input())
a, b = map(int, input().split())
x = b // k * k
if a <= x:
    print("OK")
else:
    print("NG")
p, q, r = list(map(int, input().split()))
list_ = sorted(list_)

print(list_[0]+list_[1])

### FIXED CODE ###

list_ = sorted(list(map(int, input().split())))
print(list_[0]+list_[1])
x = input()
w = "" 
for i in x: 
    w = i + w 
    if (x==w): 
        print("Yes")
	else:
      	print("No")

### FIXED CODE ###

def palindrom(st):
    return st == st[::-1]
import math
s = input()
l = len(s)
print("Yes" if palindrom(s) and palindrom(s[:(l-1)//2]) and palindrom(s[(l+2)//2:]) else "No")
a,b,c,k=map(int,input().split())
if a>=k:
  print(a)
  break
else:
  if a+b>=k:
    print(a)
    break
  else:
    print(a-(k-a-b))
    break

### FIXED CODE ###

a,b,c,k=map(int,input().split())
if a>=k:
  print(k)
else:
  if a+b>=k:
    print(a)
  else:
    print(a-(k-a-b))
H, N = map(int, input().split())
x = [list(map(int, input().split())) for n in range(N)]
x = [[tmp[i] for tmp in x] for i in range(len(x[0]))]
A = x[0]
B = x[1]

def ibis(H, A, B):
    maxA = max(A)
    HmaxA = H + maxA
    minB = min(B)
    dp = [max(B) * H] * (HmaxA + 1)
    dp[0] = 0
    for h in range(HmaxA):
        for n in range(N):
            dp[h + 1] = min(dp[h + 1], dp[h] + minB)
            hp = h + A[n]
            if hp <= HmaxA:
                dp[hp] = min(dp[hp], dp[h] + B[n])
    return min(dp[H:HmaxA+1])

print(ibis(H, A, B))

### FIXED CODE ###

H, A = map(int, input().split())
print(H // A + (H % A > 0))
if N % 2 == 0:
  print(N/2)
else:
  print((N+1)/2)
 

### FIXED CODE ###

N = int(input())
c = 0
for i in range(1, N+1):
  if i % 2 == 1:
    c+=1

print(c/N)
D,N = map(int, input().split())


if D == 0:
    n = N
elif D === 1:
    n = 100 * N 
else:
    n = 100 ** 2 * N
print(n)

### FIXED CODE ###

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

if N == 100:
    N = 101

if D == 0:
    print(N)
elif D == 1:
    print(100 * N)
else:
    print(100 ** 2 * N)
X, N = map(int, input().split())
if N == 0:
    print(X)


else:
    p = list(map(int, input().split()))
    abs_list = []
    re_list = []
    min = 1000
    min_index = 0

    for i in range(100):
        abs_list.append(i + 1)
    for j in p:
        abs_list.remove(j)
    for i in range(len(abs_list)):

        re_list.append(abs(abs_list[i] - X))
    for i in range(len(re_list)):
        if min > re_list[i]:
            min = re_list[i]
            min_index = i
    print(abs_list[min_index])


### FIXED CODE ###

X, N = map(int, input().split())
if N == 0:
    print(X)
elif N == 100:
    if X <= 50:
        print(0)
    else:
        print(101)

else:
    p = list(map(int, input().split()))
    abs_list = []
    re_list = []
    min = 1000
    min_index = 0

    for i in range(250):
        abs_list.append(-100+i)
    for j in p:
        abs_list.remove(j)
    for i in range(len(abs_list)):

        re_list.append(abs(abs_list[i] - X))
    for i in range(len(re_list)):
        if min > re_list[i]:
            min = re_list[i]
            min_index = i
    if re_list[min_index] > X:
        print(0)
    else:
        print(abs_list[min_index])
S = input()

a = input()

T = S + a

if T - a == S:
    print('YES')
else:
    print('NO')


### FIXED CODE ###

S = input()

T = input()

x = T[0:-1]

if S == x:
    print('Yes')
else:
    print('No')
def main():
    n = int(input())
    h = [int(x) for x in input().split()]
    print(f(n,h))

def f(n, h):
    if n <= 1:
        return 0
    elif n == 2:
        return abs(h[1] - h[0])
    else:
        d1 = abs(h[n-1]-h[n-2]) + f(n-1,h)
        d2 = abs(h[n-1]-h[n-3]) + f(n-2,h)
        return min(d1,d2)

if __name__ == "__main__":
    main()

### FIXED CODE ###

import sys
sys.setrecursionlimit(10**5)
def main():
    n = int(input())
    h = [int(x) for x in input().split()]
    memo = [None for i in range(n)]

    def rec(n):
        if memo[n-1] == None:
            if n <= 1:
                memo[n-1] = 0
            elif n == 2:
                memo[n-1] = abs(h[1]-h[0])
            else:
                d1 = rec(n-2)+abs(h[n-1]-h[n-3])
                d2 = rec(n-1)+abs(h[n-1]-h[n-2])
                memo[n-1] = min(d1,d2)
        return memo[n-1]
        
    print(rec(n))

if __name__ == "__main__":
    main()
#Colorful Leaderboard
import numpy as np
n = int(input())
a = np.array(list(map(int, input().split())))
b = sorted (a//400)
cnt = 0
for i in range(len(b)):s
    if b[i]  < 8:
        None
    else:
        b[i]+=i
        cnt+=1
c = len(list(set(b)))

print(str(c-cnt) + " " + str(c))

### FIXED CODE ###

#RGB card
import numpy as np
r,g,b = list(map(int, input().split()))
if((100*r+10*g+b)%4==0):
    print("YES")
else:
    print("NO")
N=input()
s=0
for i in N:
    s+=int(i)
    
if N%s==0:
    print("Yes")
else:
    print("No")

### FIXED CODE ###


N=input()
s=0
for i in N:
    s+=int(i)
    
if int(N)%s==0:
    print("Yes")
else:
    print("No")