Harryxun/stf_run huggingface dataset:
x = int(input())
t = x // 11
x -= 11 * t
ans = t * 2
if x <= 5:
    ans += 1
elif 5 < x < 11:
    ans += 2
print(ans)za

### FIXED CODE ###

x = int(input())
if x % 11 == 0:
    r = 0
elif x % 11 <= 6:
    r = 1
else:
    r = 2
ans = 2 * (x // 11) + r
print(ans)
a, b, c = map(int, input().split())
lp=[a*i/b-c for i in range(10*10)]
if 0 in ;p:
  print('YES')
else:
  print('NO')

### FIXED CODE ###

a, b, c = map(int, input().split())
lp=list((a*i%b for i in range(1,b+1)))
if c in lp:
  print('YES')
else:
  print('NO')
mport sys
s = sys.stdin.readlines()
A1_1,A1_2,A1_3= map(int, s[0].split())
A2_1,A2_2,A2_3= map(int, s[1].split())
A3_1,A3_2,A3_3= map(int, s[2].split())
N=map(int, s[3].split())
B=[]
for e in s[4:N + 4]:
    B.append(e)
a=str('yes')
b=str('no')
if A1_1 in B and A1_2 in B and A1_3 in B:
     print(a)
elif A2_1 in B and A2_2 in B and A2_3 in B:
    print(a)
elif A3_1 in B and A3_2 in B and A3_3 in B:
     print(a)
elif A1_1 in B and A2_1 in B and A3_1 in B:
    print(a)
elif A1_2 in B and A2_2 in B and A3_2 in B:
    print(a)
elif A1_3 in B and A2_3 in B and A3_3 in B:
    print(a)
elif A1_1 in B and A2_2 in B and A3_3 in B:
     print(a)
elif A1_3 in B and A2_2 in B and A3_1 in B:
    print(a)
else:
    print(b)

### FIXED CODE ###

A1_1,A1_2,A1_3 = map(int, input().split())
A2_1,A2_2,A2_3 = map(int, input().split())
A3_1,A3_2,A3_3 = map(int, input().split())
N =int(input())
B = []
for _ in range(N):
    B.append(int(input()))

a=str('Yes')
b=str('No')
if A1_1 in B and A1_2 in B and A1_3 in B:
     print(a)
elif A2_1 in B and A2_2 in B and A2_3 in B:
    print(a)
elif A3_1 in B and A3_2 in B and A3_3 in B:
     print(a)
elif A1_1 in B and A2_1 in B and A3_1 in B:
    print(a)
elif A1_2 in B and A2_2 in B and A3_2 in B:
    print(a)
elif A1_3 in B and A2_3 in B and A3_3 in B:
    print(a)
elif A1_1 in B and A2_2 in B and A3_3 in B:
     print(a)
elif A1_3 in B and A2_2 in B and A3_1 in B:
    print(a)
else:
    print(b)
s,w=map(it,input().split())
if s<=w:
  print("unsafe")
else:
  print("safe")

### FIXED CODE ###

s,w=map(int,input().split())
if s<=w:
  print("unsafe")
else:
  print("safe")
n, a, b = map(int, input().split())


ans = (n //(a + b)) * a
if n % (a + b) < a:
  print(ans + (n % (a + b))
elif n % (a + b) >= a:
  print(ans + a)
        


### FIXED CODE ###



n, a, b = map(int, input().split())
ans = n // (a + b) * a
rem = n % (a + b)
ans += min(rem, a)
print(ans)
# -*- coding: utf-8 -*-
# スペース区切りの整数の入力
a, b, c = map(int, raw_input().split())
sum = a+b+C
if sum == 17:
 print "YES"
else: 
 print "NO"

### FIXED CODE ###

# -*- coding: utf-8 -*-
# スペース区切りの整数の入力
a, b, c = map(int, raw_input().split())
sum = a+b+c
if sum == 17:
  print "YES"
else: 
  print "NO"
from math import abs
X, K, D = list(map(int, input().split()))
X = abs(X)
if(X >= K * D):
  print(X - K * D)
  return
else:
  q = X // D
  r = X // D
  if((K - q) % 2 == 0):
    print(r)
    return
  else:
    print(abs(r - D))
    return

### FIXED CODE ###

X, K, D = list(map(int, input().split()))
X = abs(X)
if(X >= K * D):
  print(X - K * D)
else:
  q = X // D
  r = X % D
  if((K - q) % 2 == 0):
    print(r)
  else:
    print(abs(r - D))
l = []
num = []

for i in range(5):
    menu = int(input())
    if menu%10 != 0:
        num.append(menu%10)
        menu = (menu//10+1)*10
    l.append(menu)

ans = sum(l)-(10-min(num))

print(ans)

### FIXED CODE ###

l = []
num = []

for i in range(5):
    menu = int(input())
    if menu%10 != 0:
        num.append(menu%10)
        menu = (menu//10+1)*10
    l.append(menu)

ans = sum(l)

if num:
    ans -= 10-min(num)

print(ans)
a, b = [int(i) for i in input().split()]

if a < b:
   print("a<b")


elif a > b:
     print("a>b")


else:
  print("a==b")

### FIXED CODE ###

a, b = [int(i) for i in input().split()]

if a < b:
   print("a < b")


elif a > b:
     print("a > b")


else:
  print("a == b")
n=int(input())
A=list(map(int,input().split()))
C=[0]*(n+1)
for i in A:
  C[i] += 1
cnt=0
ans=0
for j in reversed(range(n)):
  if C[j]>=2 and cnt==0:
    ans=j
    cnt+=1
  elif C[j]>= 2 and cnt==1:
    ans*=j
    break
print(ans)

### FIXED CODE ###

c={}
input()
for i in list(map(int,input().split())):
    if i in c:
        c[i]+=1
    else:
        c[i]=1
d=[i for i in c.items() if i[1]>1]
c=sorted(d)
if len(d)==0 or (len(d)==1 and c[-1][1]<4):
    print(0)
else:
    if c[-1][1]>3:
        print(c[-1][0]**2)
    else:
        print(c[-1][0]*c[-2][0])
import sys

def create_dict(N):
    d = {}
    for i in range(N):
        d[i+1] = set([i+1])
    return d

N, M = map(int,input().split(' '))
d = create_dict(N)
p_list = list(map(int,input().split(' ')))

x_list = []
y_list = []
for line in sys.stdin:
    x,y = map(int, line.strip().split(' '))
    d[min(x, y)].add(max(x,y))
    del d[max(x,y)]

score = 0
for i in d:
    for x in d[i]:
        if p_list[x-1] in d[i]:
            score += 1
print(score)


### FIXED CODE ###

import sys

def key2rep_iter(key, key2rep, temp_list):
    if key2rep[key] == key:
        for i in temp_list:
            key2rep[i] = key2rep[key]
        return key
    temp_list.append(key)
    return key2rep_iter(key2rep[key], key2rep, temp_list)

def add_x2y(x, y, key2rep):
    rep = key2rep_iter(y, key2rep, [])
    big_rep = key2rep_iter(x, key2rep, [])
    if rep == big_rep:
        return
    key2rep[big_rep] = rep

N, M = map(int,input().split(' '))
p_list = [int(i) for i in input().split(' ')]
key2rep = {i+1:i+1 for i in range(N)}

for line in sys.stdin:
    x,y = map(int, line.strip().split(' '))
    add_x2y(max(x,y), min(x,y), key2rep)

print(len([1 for i in range(N) if key2rep_iter(p_list[i], key2rep, []) == key2rep_iter(i+1, key2rep, [])]))
import numpy as np

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

next = np.zeros((N, N))

for i in range(M):
    u, v = map(int, input().split())
    u -= 1
    v -= 1
    next[u][v] = 1

s, t = map(int, input().split())
s -= 1
t -= 1

next = np.dot(next, np.dot(next, next))
for i in range(N):
    next[i][i] = 0

now = t
step = 0
hist = [t]
check_list = [[now, step, hist]]
ok = False
while len(check_list) > 0:
    now, step, tmp = check_list.pop(0)
    hist = tmp
    if now == s:
        print(step)
        ok = True
        break
    for i in range(N):
        if next[i][now] > 0:
            check_list.append([i, step+1, hist+[i]])
if not ok:
    print(-1)


### FIXED CODE ###

N, M = map(int, input().split())
nodes = [[] for i in range(N)]

for i in range(M):
    u, v = map(int, input().split())
    u -= 1
    v -= 1
    nodes[u].append(v)

s, t = map(int, input().split())
s -= 1
t -= 1

num = s
step = 0
q = [[num, step]]
check = [[False for i in range(N)] for j in range(3)]
ok = False
while len(q) > 0:
    num, step = q.pop(0)
    tmp = step % 3
    if tmp == 0 and num == t:
        print(step//3)
        ok = True
        break
    for next in nodes[num]:
        if not check[tmp][next]:
            check[tmp][next] = True
            q.append([next, step+1])
if not ok:
    print(-1)
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')
from sys import stdin
from collections import deque
from math import sqrt, floor, ceil, log, log2, log10, pi, gcd, sin, cos, asin
def ii(): return int(stdin.readline())
def fi(): return float(stdin.readline())
def mi(): return map(int, stdin.readline().split())
def fmi(): return map(float, stdin.readline().split())
def li(): return list(mi())
def lsi():
    x=list(stdin.readline())
    x.pop()
    return x
def si(): return stdin.readline()
############# CODE STARTS HERE #############
n=ii()
s=[0]*n
a=li()
s[n-2]=abs(a[n-2]-a[n-1])
for i in range(n-3, -1, -1):
    s[i]=min(abs(a[i]-a[i+1])+s[i+1], abs(a[i]-a[i+2])+s[i+2])
print(s[0])

### FIXED CODE ###

from sys import stdin
#from collections import deque
#from math import sqrt, floor, ceil, log, log2, log10, pi, gcd, sin, cos, asin
def ii(): return int(stdin.readline())
def fi(): return float(stdin.readline())
def mi(): return map(int, stdin.readline().split())
def fmi(): return map(float, stdin.readline().split())
def li(): return list(mi())
def lsi():
    x=list(stdin.readline())
    x.pop()
    return x
def si(): return stdin.readline()
############# CODE STARTS HERE #############
n=ii()
s=[0]*n
a=li()
s[n-2]=abs(a[n-2]-a[n-1])
for i in range(n-3, -1, -1):
    s[i]=min(abs(a[i]-a[i+1])+s[i+1], abs(a[i]-a[i+2])+s[i+2])
print(s[0])
A,B = map(int,input().split(' '))
num = 0
for str(x) in range(A,B+1):
  if str(x) == str(x)[::-1]:
    num += 1
print(num)

### FIXED CODE ###

A,B = map(int,input().split(' '))
num = 0
for x in range(A,B+1):
  if str(x) == str(x)[::-1]:
    num += 1
print(num)
import sympy
N=int(input())
list=list()
for i in range(105,N+1,2):
    dict=sympy.factorint(i)
    result=2**sum(dict.values())
    if result >=8:
        list.append(i)
print(len(list))


### FIXED CODE ###

N=int(input())
list=list()
cnt=0
for i in range(105,N+1,2):
    list=[j for j in range(1,200)if i%j<1]
    if len(list) >=8:
        cnt+=1
print(cnt)
r,g,b,n=map(int,input().split()):
ans=0
for i in range(0,3001):
  for j in range(0,3001):
    if (n-i*r-j*g)%b==0:
      ans+=1
print(ans)

### FIXED CODE ###

r,g,b,n=map(int,input().split())
ans=0
for i in range(0,3001):
  for j in range(0,3001):
    if (n-i*r-j*g)%b==0 and (n-i*r-j*g)>=0:
      ans+=1
print(ans)
N = int(input())
A = list(map(int, input().split()))
if N == 1:
    print("Yes")
else:
    k = 0
    for i in range (N-1):
        if A[N-(1 + i)] < A[N-(2 + i)]:
            if (A[N-(2 + i)] - A[N-(1 + i)]) == 1:
                A[N-(2 + i)] -= 1
            else:
                k = 114514
if k == 114514:
    print("No")
else:
    print("Yes")             

### FIXED CODE ###

N = int(input())
A = list(map(int,input().split()))
ans = 0
for i in range(N-1):
  if ans > A[i+1]:
    print('No')
    exit()
  if A[i+1]-A[i] >= -1:
    ans = max(A[i+1]-1,A[i]-1,ans)
    if A[i+1] >= A[i] and A[i+1] > ans :
      A[i+1] -=1
  else:
    print('No')
    exit()
print('Yes')
n=input().split()
if a.count("5")==2 and a.count("7")==1:
   print("YES")
else:
   print("NO")

### FIXED CODE ###

a=input().split()
if a.count("5")==2 and a.count("7")==1:
   print("YES")
else:
   print("NO")
from sys import stdin


if __name__ == "__main__":
    _in = [_.rstrip() for _ in stdin.readlines()]
    r,g,b = list(map(int,_in[0].split(' ')))  # type:list(int)
    # vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
    TF = 'YES' if int(f'{r}{g}{b}')%4==0 else 'NO'
    # ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    print(TF)


### FIXED CODE ###

from sys import stdin


if __name__ == "__main__":
    _in = [_.rstrip() for _ in stdin.readlines()]
    r,g,b = _in[0].split(' ')  # type:list(str)
    # vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
    TF = 'YES' if int(r+g+b)%4==0 else 'NO'
    # ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    print(TF)
import functools
import math

N,X = list(map(int,input().strip().split()))
xs = list(map(int,input().strip().split()))

diffs = [abs(X - x) for x in xs]

print(functools.reduce(math.gcd,diffs))

### FIXED CODE ###

import functools

def gcd(x,y):
    big = max(x,y)
    small = min(x,y)
    while small > 0:
        big, small = small, big % small

    return big

N,X = list(map(int,input().strip().split()))
xs = list(map(int,input().strip().split()))

diffs = [abs(X - x) for x in xs]

print(functools.reduce(gcd,diffs))
a = int(raw_input())
b = int(raw_input())

if a<=8 and b<=8:
    print "Yay!"
else:
    print ":("

### FIXED CODE ###

a, b = map(int, raw_input().split())

if a<=8 and b<=8:
    print "Yay!"
else:
    print ":("
n = int(input())
A = [int(input()) for i in range(n)] 

counter = [0]*n
cnt = 0
for a in A:
    counter[a-1] += 1
for c in counter:
    if c == 1:
        cnt += 1
print(cnt)


### FIXED CODE ###

N = input()
result = "No"
for i in N:
    if i == '9':
        result = "Yes"
print(result)
#!/usr/bin/env python

import sys
input = sys.stdin.buffer.readline
sys.setrecursionlimit(10**6)
INF = float("inf")

def popcount(n):
    ret = 0
    for i in range(18):
        if n>>i & 1:
            ret += 1
    return ret

def main():
    N = int(input())
    X = input().decode().rstrip()

    # X に含まれる "1" の数
    x_cnt = 0
    for i in range(N):
        if X[i] == "1":
            x_cnt += 1

    # i 桁目が 0 : x_cnt += 1
    # i 桁目が 1 : x_cnt -= 1
    # より, X mod x_cnt +1, X mod x_cnt-1 を事前計算しておく
    n_plus,n_minus = 0,0
    t_plus,t_minus = 1,1
    for i in range(N-1,-1,-1):
        if X[i]=="1":
            n_plus += t_plus
            n_plus %= x_cnt + 1
            n_minus += t_minus
            n_minus %= x_cnt - 1
        t_plus = (t_plus*2) % (x_cnt + 1)
        t_minus = (t_minus*2) % (x_cnt - 1)
    
    for i in range(N):
        ans = 1
        if X[i] == "1":
            # 1 -> 0 に変換した結果, １が全く存在しない場合
            #if x_cnt == 1:
            #    print(0)
            #    continue
            a = (n_minus - pow(2,(N-1-i), x_cnt-1)) % (x_cnt-1)
        else:
            a = (n_plus + pow(2,(N-1-i), x_cnt+1)) % (x_cnt+1)

        while a > 0:
            pop_cnt = popcount(a)
            a %= pop_cnt
            ans += 1

        print(ans)

if __name__ == "__main__":
    main()

### FIXED CODE ###

#!/usr/bin/env python

import sys
input = sys.stdin.buffer.readline
sys.setrecursionlimit(10**6)
INF = float("inf")

def popcount(n):
    ret = 0
    for i in range(18):
        if n>>i & 1:
            ret += 1
    return ret

def main():
    N = int(input())
    X = input().decode().rstrip()

    # X に含まれる "1" の数
    x_cnt = X.count("1")

    # i 桁目が 0 : x_cnt += 1
    # i 桁目が 1 : x_cnt -= 1
    # より, X mod x_cnt +1, X mod x_cnt-1 を事前計算しておく
    x_mod_pl,x_mod_mi = 0,0
    d_pl,d_mi = 1,1
    mod_pl,mod_mi = x_cnt+1,max(1,x_cnt-1)
    for i in range(N-1,-1,-1):
        if X[i]=="1":
            x_mod_pl = (x_mod_pl + d_pl) % mod_pl
            x_mod_mi = (x_mod_mi + d_mi) % mod_mi
        d_pl = (d_pl*2) % mod_pl
        d_mi = (d_mi*2) % mod_mi
    
    for i in range(N):
        ans = 1
        if X[i] == "1":
            # 1 -> 0 に変換した結果, １が全く存在しない場合
            if x_cnt == 1:
                print(0)
                continue
            a = (x_mod_mi - pow(2,(N-1-i), mod_mi)) % mod_mi
        else:
            a = (x_mod_pl + pow(2,(N-1-i), mod_pl)) % mod_pl

        while a > 0:
            pop_cnt = popcount(a)
            a %= pop_cnt
            ans += 1

        print(ans)

if __name__ == "__main__":
    main()
import bisect
n,k=map(int,input().split())
a=list(map(int,input().split()))
a.sort()
fa = a[:bisect.bisect_left(a,k)]
fa.reverse()
nn = len(fa)
for i in range(nn):
    flag = 0
    ta = fa[i]
    na = fa[:i]+fa[i+1:]
    dp = [False for _ in range(k+1)]
    dp[0]=True
    for j in range(nn-1):
        for l in range(k,0,-1):
            if l-na[j]>=0:
                dp[l]=dp[l] or dp[l-na[j]]
    for j in range(k-ta,k):
        if dp[j]:
            flag = 1
            break
    if flag == 0:
        res = i
        break
print(nn-i)



### FIXED CODE ###

import bisect
def main():
    n,k=map(int,input().split())
    a=list(map(int,input().split()))
    a.sort()
    l=0
    r=n
    d = {}
    if sum(a)<k:
        print(n)
    else:
        while l!=r:
            i=(l+r)//2
            ta = a[i]
            if ta in d.keys():
                flag = d[ta]
            elif ta>=k:flag=True
            else:
                flag = False
                na = a[:i]+a[i+1:]
                dp = [False for _ in range(k+1)]
                dp[0]=True
                for j in range(n-1):
                    for m in range(k,0,-1):
                        if m-na[j]>=0:
                            dp[m]=dp[m] or dp[m-na[j]]
                        if m != k and m>=k-ta and dp[m]:
                            flag = True
                            break
                    if flag:break
                d[ta] = flag
            
            if flag:
                r=i
            else:
                l=i+1
        print(l)

main()
import sys
import math

lines = str(sys.stdin.read()).strip().split("\n")

for line in lines:
    line = int(line)
    pList = []
    sList = list(reversed(list(range(3, line + 1))[::2]))
    while sList[-1] < int(math.ceil(math.sqrt(line))) + 1:
        pList.append(sList.pop())
        for p in pList:
            sList = list(filter(lambda i: i % p != 0, sList))
    pList.extend(sList)
    pList.append(2)
    print(len(pList))

### FIXED CODE ###

import sys
import math


LIMIT = 1000000
p = 2
pList = [True] * (LIMIT + 1)


while p ** 2 <= LIMIT:
    if(pList[p]):
        for i in range(p * 2, LIMIT + 1 , p):
            pList[i] = False
    p += 1

# print(pList)


lines = str(sys.stdin.read()).strip().split("\n")

for line in lines:
    line = int(line)
    count = 0
    for i in range(2, line + 1):
        if pList[i]:
            count += 1
    print(count)
# coding:utf-8

if __name__=="__main__":
  R,G,B,N = map(int, input().split())
  count = 0
  for r in range(int(N/R)+1):
    n1 = N - r*R
    for g in range(int(n1/G)+1):
      n2 = n1 - g*G
      if n2%B==0: count+= 1
  print(count)

### FIXED CODE ###

# coding:utf-8

if __name__=="__main__":
  N, K = map(int, input().split())
  print(N-K+1)
while True:
&#160;&#160;&#160;&#160;ts={}
&#160;&#160;&#160;&#160;c=input()
&#160;&#160;&#160;&#160;if c==0: break
&#160;&#160;&#160;&#160;for i in range(c):
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;f=raw_input().split()
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;ts[f[0]]=int(f[1])
&#160;&#160;&#160;&#160;for i in range(input()):
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;f=raw_input().split()
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;m=0
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;for j in range(int(f[1])):
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;h=ts[f[j+2]] if f[j+2] in ts else 0
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;m+=h
	q=ts[f[0]]
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;ts[f[0]]=q if m > q else m
&#160;&#160;&#160;&#160;print ts[raw_input()]

### FIXED CODE ###

q,w,e=range,input,raw_input
while True:
  n=w()
  if n==0:break
  d={}
  for i in q(n):
    o=e().split()
    d[o[0]]=int(o[1])
  for j in q(w()):
    t=e().split()
    a=sum([d[i] if i in d else 0 for i in t[2:]])
    d[t[0]]=a if a<d[t[0]] else d[t[0]]
  print d[e()]
import sys
H, W = map(int, input().split())
s = [input() for i in range(H)]
S = []
S.append('.' * (W + 2))
for i in range(W):
    S.append('.' + s[i] + '.')
S.append('.' * (W + 2))
for i in range(1, H + 1):
    for j in range(1, W + 1):
        if S[i][j] == '#':
            if S[i + 1][j] == '#' or S[i - 1][j] == '#' or S[i][j + 1] == '#' or S[i][j - 1] == '#':
                continue
            else:
                print('No')
                sys.exit()
print('Yes')

### FIXED CODE ###

import sys
H, W = map(int, input().split())
s = []
s.append('.' * (W + 2))
for i in range(1, H + 1):
    a = input()
    a = '.' + a + '.'
    s.append(a)
s.append('.' * (W + 2))
for i in range(1, H + 1):
    for j in range(1, W + 1):
        if s[i][j] == '#':
            OK = False
            if s[i - 1][j] == '#' or s[i + 1][j] == '#' or s[i][j - 1] == '#' or s[i][j + 1] == '#':
                OK = True
            if OK == False:
                print('No')
                sys.exit()
print('Yes')
N, *ABC = map(int, input().split())
s = [input() for _ in range(N)]

yes_flag = True
ans_list = []

if sum(ABC) == 0:
    yes_flag = False

for i in range(N):
    if not yes_flag:
        break
    u = ord(s[i][0]) - 65
    v = ord(s[i][1]) - 65
    if ABC[u] + ABC[v] == 0:
        yes_flag = False
    elif ABC[u] + ABC[v] == 1:
        if ABC[u] == 1:
            ans_list += [s[i][0]]
            ABC[u] -= 1
            ABC[v] += 1
        else:
            ans_list += [s[i][1]]
            ABC[v] -= 1
            ABC[u] += 1
    elif ABC[u] + ABC[v] == 2:
        # 両方1の場合だけケアが必要
        if ABC[u] * ABC[v] == 1:
            if i == N-1:
                ans_list += [s[i][0]]
            else:
                if ABC[u] in s[i+1]:
                    ans_list += [s[i][0]]
                    ABC[u] -= 1
                    ABC[v] += 1
                else:
                    ans_list += [s[i][1]]
                    ABC[v] -= 1
                    ABC[u] += 1
        else:
            if ABC[u] > 1:
                ans_list += [s[i][0]]
                ABC[u] -= 1
                ABC[v] += 1
            else:
                ans_list += [s[i][1]]
                ABC[v] -= 1
                ABC[u] += 1
    else:
        if ABC[u] > 1:
            ans_list += [s[i][0]]
            ABC[u] -= 1
            ABC[v] += 1
        else:
            ans_list += [s[i][1]]
            ABC[v] -= 1
            ABC[u] += 1

if yes_flag:
    print("Yes")
    print(*ans_list)

else:
    print("No")


### FIXED CODE ###

N, *ABC = map(int, input().split())
s = [input() for _ in range(N)]

yes_flag = True
ans_list = []

if sum(ABC) == 0:
    yes_flag = False

for i in range(N):
    if not yes_flag:
        break
    u = ord(s[i][0]) - 65
    v = ord(s[i][1]) - 65
    if ABC[u] + ABC[v] == 0:
        yes_flag = False
    elif ABC[u] + ABC[v] == 1:
        if ABC[u] == 1:
            ans_list += [s[i][1]]
            ABC[u] -= 1
            ABC[v] += 1
        else:
            ans_list += [s[i][0]]
            ABC[v] -= 1
            ABC[u] += 1
    elif ABC[u] + ABC[v] == 2:
        # 両方1の場合だけケアが必要
        if ABC[u] * ABC[v] == 1:
            if i == N-1:
                if ABC[u] > 0:
                    ans_list += [s[i][1]]
                else:
                    ans_list += [s[i][0]]
            else:
                if s[i][1] in s[i+1]:
                    ans_list += [s[i][1]]
                    ABC[u] -= 1
                    ABC[v] += 1
                else:
                    ans_list += [s[i][0]]
                    ABC[v] -= 1
                    ABC[u] += 1
        else:
            if ABC[u] > 1:
                ans_list += [s[i][1]]
                ABC[u] -= 1
                ABC[v] += 1
            else:
                ans_list += [s[i][0]]
                ABC[v] -= 1
                ABC[u] += 1
    else:
        if ABC[u] > 1:
            ans_list += [s[i][1]]
            ABC[u] -= 1
            ABC[v] += 1
        else:
            ans_list += [s[i][0]]
            ABC[v] -= 1
            ABC[u] += 1

if yes_flag:
    print("Yes")
    print(*ans_list)
else:
    print("No")
import sys
input = sys.stdin.readline
n, m = [int(x) for x in input().rstrip().split()]
a = [int(x)//2 for x in input().rstrip().split()]
a = list(set(a))

def find_gcd(a, b):
    if b == 0:
        return a
    return find_gcd(b, a % b)


gcd = a[0]
product = 1
for x in a:
    gcd = find_gcd(gcd, x)
    product *= x

lcm = product // gcd

for x in a:
    if (lcm // x) % 2 == 0:
        print(0)
        sys.exit(0)

print((m // lcm + 1) // 2)


### FIXED CODE ###

import sys
input = sys.stdin.readline

k, x = [int(x) for x in input().rstrip().split()]
print('Yes' if k * 500 >= x else 'No')
def abc070_c():
    from fractions import gcd
    n = int(input())
    t = [int(input()) for _ in range(n)]
    ans = 1
    for i in range(n):
        ans = int(ans * t[i] / gcd(ans, t[i]))

    print(ans)


abc070_c()

### FIXED CODE ###

def abc070_c():
    from fractions import gcd
    n = int(input())
    t = [int(input()) for _ in range(n)]
    ans = t[0]
    for v in t:
        ans = ans * v // gcd(ans, v)

    print(ans)


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

def Is_prime(n):
    if n % 2 == 0:
        return False
    i = 3
    while i < int(n ** (0.5))+ 1:
        if n % i == 0:
            return False
    return True

count = 0
for j in n:
    if Is_prime(j):
        count += 1

print (count)

### FIXED CODE ###

N = int(input())
n = [int(input()) for i in range(N)]

def Is_prime(n):
    if n == 2:
        return True
    if n == 1:
        return False
    if n % 2 == 0:
        return False
    i = 3
    while i < int(n ** (0.5))+ 1:
        if n % i == 0:
            return False
        i += 2
    return True

count = 0
for j in n:
    if Is_prime(j):
        count += 1

print (count)