Harryxun/stf_run huggingface dataset:
A, B = map(int, input().split())
for i in range(1, 4):
	x = A *B *i
    if ((x % 2) == 1):
      print('Yes')
	  break
else:
  print('No')
  

### FIXED CODE ###

import sys
A, B = map(int, input().split())
for i in range(1, 4):
    x = A *B *i
    if ((x % 2) == 1):
      print('Yes')
      sys.exit()
else:
  print('No')
S = input()
K = int(input())

k = -1
while S[k+1] == "1":
  k += 1
  print(k)

if K <= k:
  print(1)
else:
  print(S[k+1])

### FIXED CODE ###

import sys
S = input()
K = int(input())

for i in range(K):
  if S[i] != "1":
    print(S[i])
    sys.exit()
print(1)
n = int(input())
nums = list(map(int,input().split()))
dp = [[0,0,0] for _ in range(n)]
dp[0][0] = nums[0]
dp[1][0],dp[1][1],dp[1][2] = nums[1],nums[0],-float("inf")
dp[2][0],dp[2][1],dp[2][2] = nums[2],nums[1],nums[0]
for i in range(3,n):
    if i%2 == 0:
        dp[i][0] = max(dp[i-2]) + nums[i]
        dp[i][1] = max(dp[i-3]) + nums[i-1]
        dp[i][2] = sum(nums[0:i-1:2])
    else:
        dp[i][0] = max(dp[i-2]) + nums[i]
        dp[i][1] = sum(nums[0:i-2:2]) + nums[i-1]
        dp[i][2] = -float("inf")
print(max(dp[n-1]))
print(dp)

### FIXED CODE ###

n = int(input())
nums = list(map(int,input().split()))
if n == 2:
    print(max(nums[0],nums[1]))
else:
    temp =[0]
    for i in range(n):
        if i%2 == 0:
            temp += [temp[-1]+nums[i]]
    dp = [[0,0,0] for _ in range(n)]
    dp[0][0] = nums[0]
    dp[1][0],dp[1][1],dp[1][2] = nums[1],nums[0],-float("inf")
    dp[2][0],dp[2][1],dp[2][2] = nums[2],nums[1],nums[0]
    for i in range(3,n):
        if i%2 == 0:
            dp[i][0] = max(dp[i-2]) + nums[i]
            dp[i][1] = max(dp[i-3]) + nums[i-1]
            dp[i][2] = temp[i//2]
        else:
            dp[i][0] = max(dp[i-2]) + nums[i]
            dp[i][1] = temp[(i-1)//2] + nums[i-1]
            dp[i][2] = -float("inf")
    print(max(dp[n-1]))
n, k = map(int, input().split())
s = input()
c = 1
l = []

if s[0] == '0':
    l.append(0)

for i in range(1, n):
    if s[i-1] != s[i]:
        l.append(c)
        c = 1
    else: 
        c +=1
l.append(c)

if s[0] == '0':
    l.append(0)

ll = len(l)
pl = 2 * k + 1

if ll <= pl:
    t = 0
    for i in range(ll):
        t += l[i]
    print(t)
else:
    t = 0
    for i in range(0,pl):
      t += l[i]
    m = t
    for i in range(0, ll-pl, 2):
        t += l[pl+i] + l[pl+i+1]
        t -= l[i]    + l[i+1]
        m = t if (t > m) else m
    print(m)


### FIXED CODE ###

n, k = map(int, input().split())
s = input()
c = 1
l = []

if s[0] == '0':
    l.append(0)

for i in range(1, n):
    if s[i-1] != s[i]:
        l.append(c)
        c = 1
    else: 
        c +=1
l.append(c)

if s[n-1] == '0':
    l.append(0)

ll = len(l)
pl = 2 * k + 1

if ll <= pl:
    t = 0
    for i in range(ll):
        t += l[i]
    print(t)
else:
    t = 0
    for i in range(0,pl):
      t += l[i]
    m = t
    for i in range(0, ll-pl, 2):
        t += l[pl+i] + l[pl+i+1]
        t -= l[   i] + l[   i+1]
        m = t if (t > m) else m
    print(m)
def gcd(a, b):
        while b:
            a, b = b, a % b
        return a
     
    N, X = input().split()
    xList = [int(x) for x in input().split()]
    N = int(N)
    X = int(X)
    xList.append(X)
    xList.sort()
    diffList = []
    for x, xx in zip(xList, xList[1:]):
        diffList.append(xx - x)
    if len(diffList) > 1:
        diffList.sort()
        gcdList = []
        for x in diffList[1:]:
            gcdList.append(gcd(diffList[0], x))
        gcdList.sort()
        print(gcdList[0])
    else:
        print(diffList[0])

### FIXED CODE ###

def gcd(a, b):
    while b:
        a, b = b, a % b
    return a
    
N, X = input().split()
xList = [int(x) for x in input().split()]
N = int(N)
X = int(X)
xList.append(X)
xList.sort()
diffList = []
for x, xx in zip(xList, xList[1:]):
    diffList.append(xx - x)
if len(diffList) > 1:
    diffList.sort()
    gcdList = []
    for x in diffList[1:]:
        gcdList.append(gcd(diffList[0], x))
    gcdList.sort()
    print(gcdList[0])
else:
    print(diffList[0])
N = int(input())
A = list(map(int, input().split()))
for i in range(N):
    A[i] = A[i] - i-1
sorted(A)
halfN = int(N/2)
x = 0
for i in range(N):
    x = x + abs(A[i] - A[halfN])
print(x)

### FIXED CODE ###

N = int(input())
z = N
if N % 2 != 0:
    z = 2 * N
print(z)
input_num = raw_input()

print num^3

### FIXED CODE ###

num = input()

print num**3
A,M = list(map(int,input().split()))
x = [0 in range(A)]
y = [0 in range(A)]
z = [0 in range(A)]
w = [0 in range(A)]
ans = 0
for i in range(A):
    x[i],y[i],z[i] = list(map(int,input().split()))
for a in [1,-1]:
    for b in [1,-1]:
        for c in [1,-1]:
            tx = [ a * i for i in range(x)]
            ty = [b * i for i in range(y)]
            tz = [ c * i for i in range(z)]
            for i in range(A):
                w[i] = tx[i] + ty[i] + tz[i]
            tw = sum(sorted(w)[::-1][:M])
            if tw > ans:
                ans = tw
print(ans)


### FIXED CODE ###

A,M = list(map(int,input().split()))
ans = 0
x = []
y = []
z = []
w = [0 for i in range(A)]
for i in range(A):
    a,b,c = list(map(int,input().split()))
    x.append(a)
    y.append(b)
    z.append(c)
for aa in [1,-1]:
    for bb in [1,-1]:
        for cc in [1,-1]:
            #print(a)
            #print(x)
            tx = [ aa * j for j in x]
            ty = [ bb * j for j in y]
            tz = [ cc * j for j in z]
            for j in range(A):
                w[j] = tx[j] + ty[j] + tz[j]
            tw = sum(sorted(w)[::-1][:M])
            if tw > ans:
                ans = tw
print(ans)
from collections import defaultdict
import sys
sys.setrecursionlimit(10**6)
n , k = map(int , input().split())
arr = list(map(int , input().split()))
dic = defaultdict(int)
for i in range(1,n+1):
	dic[i] = arr[i-1]
cycle = []
def dfs(node):
	if node in cycle:
		return node
	else:
		cycle.append(node)
		k = dfs(dic[node])
	return k
cyele = dfs(1)
ind = 0
offset = 0
for i in range(len(cycle)):
	if cycle[i] == cyele:
		ind = i
		break
	offset+=1
#rem = k - offset
csize = len(cycle[ind:])
rem=rem%csize

count = 0
curr = 1
while count != rem:
	curr = dic[curr]
	count+=1
print(curr)


### FIXED CODE ###

from collections import defaultdict
import sys
sys.setrecursionlimit(10**6)
n , k = map(int , input().split())
arr = list(map(int , input().split()))
dic = defaultdict(int)
for i in range(1,n+1):
	dic[i] = arr[i-1]
cycle = []
visited = [False]*(10**6)
curr = 1
while True:
	cycle.append(curr)
	visited[curr] = True
	curr = dic[curr]
	#k -= 1
	if visited[curr]:
		break

csize = 0
ind = 0
for i in range(len(cycle)-1,-1,-1):
	if cycle[i] == curr:
		ind = i + 1
		break
	csize += 1
offset = len(cycle) - csize - 1
#print(cycle,csize+1, k , curr,offset)
if k - offset < 0:
	exit(print(cycle[k]))
k -= offset
k %= csize + 1
print(cycle[offset + k])
def main():
    n,m = map(int, input().split())
    H = list(map(int,input().split()))
    # array = [list(map(int,input().split())) for _ in range(m)]
    pool = set(range(1, n+1))

    for i in range(m):
        a,b = map(int,input().split())
        # a,b = array[i]
        if H[a-1] < H[b-1]:
            pool = pool - set([a])
        else:
            pool = pool - set([b])

    print(len(pool))


if __name__ == '__main__':
    main()


### FIXED CODE ###

def main():
    S = input()

    if S=='ABC':
        print('ARC')
    else:
        print('ABC')


if __name__ == '__main__':
    main()
s = input()
K = int(input())
s_list = []
for i in range(len(s)):
	for j in range(1, K):
		s_list.append(s[i:j])
s_set = set(s_list)
ans = list(s_set.sort())
print(ans[K - 1])

### FIXED CODE ###

s = input()
K = int(input())
substr = set()
for i in range(len(s)):
    for j in range(i+1, i+K+1):
        substr.add(s[i:j])
print(sorted(substr)[K-1])
from bisect import bisect_right
from sys import setrecursionlimit

setrecursionlimit(10**8)
n = int(input())
A = list(map(int, input().split()))
gr = []
for i in range(n):
    gr.append([])
for i in range(n - 1):
    a, b = map(int, input().split())
    a -= 1
    b -= 1
    gr[a].append(b)
    gr[b].append(a)
ans = [0] * n
dp = [10 ** 10 for i in range(n)]
dp[0] = -10 ** 10
kek = 1
used = {0}


def dfs(v):
    global kek
    j = bisect_right(dp, A[v])
    old = -1
    if dp[j - 1] < A[v] < dp[j]:
        old = dp[j]
        dp[j] = A[v]
        if kek == j:
            for h in range(kek + 1, n + 1):
                if dp[h] == 10 ** 10:
                    kek = h
                    break
    ans[v] = kek - 1
    for u in gr[v]:
        if u not in used:
            used.add(u)
            dfs(u)
    dp[j] = old
    if kek > j and old == 10 ** 10:
        kek = j


dfs(0)
print(*ans)

### FIXED CODE ###

from bisect import bisect_right
from sys import setrecursionlimit

setrecursionlimit(10**8)
n = int(input())
A = list(map(int, input().split()))
gr = []
for i in range(n):
    gr.append([])
for i in range(n - 1):
    a, b = map(int, input().split())
    a -= 1
    b -= 1
    gr[a].append(b)
    gr[b].append(a)
ans = [0] * n
dp = [10 ** 10 for i in range(1 + n)]
dp[0] = -10 ** 10
kek = 1
used = {0}


def dfs(v):
    global kek
    j = bisect_right(dp, A[v] - 1)
    old = dp[j]
    if dp[j - 1] < A[v] < dp[j]:
        old = dp[j]
        dp[j] = A[v]
        if kek == j:
            for h in range(kek + 1, 1 + n):
                if dp[h] == 10 ** 10:
                    kek = h
                    break
            if kek == j:
                kek = n + 1
    ans[v] = kek - 1
    for u in gr[v]:
        if u not in used:
            used.add(u)
            dfs(u)
    dp[j] = old
    if kek > j and old == 10 ** 10:
        kek = j


dfs(0)
print(*ans)
R,G,B,M = map(int,input().split())
cnt = 0
for r in range(3001):
  for g in range(r):
    for b in range(g):
      if N = r * R + g * G +b * B:
        cnt += 1
      else:
        continue
print(cnt)

### FIXED CODE ###

R,G,B,N = map(int,input().split())
cnt = 0
for r in range((N // R) + 1):
    for g in range((N - (r * R)) // G + 1):
        V = N - (r * R + g * G)
        if V >= 0 and V % B == 0:
            cnt += 1
print(cnt)
a = input()
b = input()
s = a * b
l = 2 * (a+b)

print "%d %d" % (s, l)

### FIXED CODE ###

tmp = raw_input().split()
a = int(tmp[0])
b = int(tmp[1])
s = a * b
l = 2 * (a+b)

print "%d %d" % (s, l)
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([:-1]))


### 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 heapq
def SME(start,end):
    if end > N : end = N
    count = 0
    for i,x in enumerate(Whole[start:end]):
        heapq.heappush(A,[x,i])
    for j in range(start,end):
        a = heapq.heappop(A)
        if None not in ANS[a[1]:a[1]+L] : continue
        for i in range(L):
            idx = a[1] + i
            try :
                if ANS[idx] : continue
                else :
                    ANS[idx] = a[0]
                    D.Add(idx)
                    count += 1
            except IndexError : continue
        if count > N * parameter : break
    for i in C.difference(D):
        if i < L:
            ANS[i] = min(Whole[:i+1])
        else :
            ANS[i] = min(Whole[i+1-L:i+1])
    return ANS
[N,L] = [int(x) for x in input().split()]
Whole = [int(x) for x in input().split()]
A = []
C = set([i for i in range(N)])
D = {}
parameter = 0.99
ANS = [None]*N
ANS = SME(0, N)
for i in ANS[L-1:-1]:print(i, end=" ")
print(ANS[-1])

### FIXED CODE ###

def ascend(a,b):
    mini = min(A[a:a+L])
    ans[a] = mini
    for i in range(a+1,b):
        if A[i+L-1] <= mini : mini = A[i+L-1]
        elif A[i-1] == mini : mini = min(A[i:i+L])
        ans[i] = mini

def descend(a,b):
    mini = min(A[b-1:b+L-1])
    ans[b-1] = mini
    for i in range(b-2,a-1,-1):
        if A[i] <= mini : mini = A[i]
        elif A[i+L] == mini: mini = min(A[i:i+L])
        ans[i] = mini
    
[N,L] = [int(x) for x in input().split()]
A = [int(x) for x in input().split()]
ans = [None]*(N-L+1)
count = 0;
if N > 10 ** 4:
    for i in range(100):
        if A[i+1] > A[i] : count += 1
    if count > 80 : descend(0, N-L+1)
    else : ascend(0,N-L+1)
else :
    ascend(0, N-L+1)
for i in ans[:-1] : print(i, end=" ")
print(ans[-1])
A, B=map(int, input())
print(A+B if B%A==0 else B-A)

### FIXED CODE ###

A, B=map(int, input().split())
print(A+B if B%A==0 else B-A)
atcoder.py

### FIXED CODE ###

S = input()

a = 1
b = 1
first = S[0]
second = ""
for i in range(3):
    if S[i+1] == first:
        a += 1
    elif second == "":
        second = S[i+1]
    elif second == S[i+1]:
        b+= 1

if a == 2 and b == 2:
    print("Yes")
else:
    print("No")
N,M = map(int,input().split(" "))
p = []
S = []
flag_AC = []
flag_WA = []

for i in range(M):
    inp = input().split(" ")
    p.append(int(inp[0]))
    S.append(inp[1])
    flag_AC.append(0)
    flag_WA.append(0)

# n番目の提出ステータスを取得
def Anc(n):
    L = []
    L.append(p[n])
    L.append(S[n])
    return L

AC = 0
WA = 0

for i in range(M):
    data = Anc(i)
    if data[1] == "AC":
        if flag_AC[data[0]] == 0:
            flag_AC[data[0]] = 1
            AC = AC + 1

    if data[1] == "WA" and flag_AC[data[0]] == 0:
        flag_WA[data[0]] = flag_WA[data[0]] + 1
        WA = WA+1

print(AC,WA)

### FIXED CODE ###

N,M=map(int,input().split())
ac=[0]*N
wa=[0]*N
pena=0
acsum=0
for i in range(M):
    p,S=input().split()
    p=int(p)-1
    if S == 'AC':
        if ac[p]==0:
            ac[p]=1
            pena+=wa[p]
            acsum+=1
    else:
        wa[p]+=1
print(acsum,pena)
print(input.count('1'))

### FIXED CODE ###

print(input().count("1"))
import fractions
import functools

def main():
    n = int(input())
    a = [int(t)for t in input().split()]

    a_gcd = functools.reduce(fractions.gcd,a)
    a = [x//a_gcd for x in a]
    gcdlist = []

    max = 1
    for i in range(n):
        t = a
        del t[i]
        t_gcd = functools.reduce(fractions.gcd,t)
        max = t_gcd if t_gcd>max else max

    print(a_gcd*max(gcdlist))
    
if __name__ == "__main__":
    main()

### FIXED CODE ###

import fractions
import functools

def main():
    n = int(input())
    a = [int(t)for t in input().split()]

    a_gcd = functools.reduce(fractions.gcd,a)
    a = [x//a_gcd for x in a]
    
    a_rev = a[::-1]

    lgcd = [0]
    rgcd = [0]
    for i in range(n):
        l = fractions.gcd(a[i],lgcd[i])
        r = fractions.gcd(a_rev[i],rgcd[i])
        lgcd.append(l)
        rgcd.append(r)

    rgcd = rgcd[::-1]
    g = [fractions.gcd(lgcd[i],rgcd[i+1]) for i in range(n)]
    
    print(max(g)*a_gcd)
    
    
if __name__ == "__main__":
    main()
import copy
x,n = list(map(int, input("").split()))
p = list(map(int, input("").split()))

mina =101
y = []
minc = []

for x not in p:
    print(x)
    exit()

for i in range(1,101):
    y.append(i)

if n == 0:
    print(x)
else:
    for j in range(n):
        y.remove(p[j])

    z = copy.copy(y)

    for k in range(len(y)):
        if abs(x - y[k]) < mina:
            mina = abs(x - y[k])
            minb = y[k]
            z.remove(minb)

    minc.append(minb)
    mina = 101

    for m in range(len(z)):
        if abs(x - z[m]) < mina:
            mina = abs(x - z[m])
            minb = z[m]

    minc.append(minb)

    print(min(minc))

### FIXED CODE ###

x,n = list(map(int, input("").split()))
p = list(map(int, input("").split()))

for i in range(101):
    if x-i not in p:
        print(x-i)
        exit()
    elif x+i not in p:
        print(x+i)
        exit()
l,n=(int(x) for x in input().split())
sente1=input()
sente2=input()
sente3=input()
mylist=[sente1,sente2,sente3]
mylist.sort()
print(''.join(mylist))

### FIXED CODE ###

# 入力
N,L=map(int,input().split())

l=[]
for i in range(N):
  l.append(input())

# ソート
l.sort()

# 出力
print(''.join(l))
import sys

def mink(numk,l):
    x = 1
    for _ in range(k):
        x = a[x-1]
    return x

input = sys.stdin.readline
n,k = map(int,input().split())
a = list(map(int,input().split()))

# kが小さい時
if k <= 10**3:
    print(mink(k,a))
    sys.exit()

z = 1
p = [1]
for _ in range(k):
    z = a[z-1]
    if z in p:
        p.append(z)
        break
    p.append(z)

# 周期の来る前の回数
num = p.index(p[-1])

p = p[num:]

# 周期
pn = len(p)-1

k -= num

# 回数/周期のあまり
anum = k%pn
print(p[anum])

### FIXED CODE ###

import sys

input = sys.stdin.readline
n,k = map(int,input().split())
a = list(map(int,input().split()))

p = [1]
for i in range(n):
    p.append(a[p[i]-1])

if k <= n:
    print(p[k])
else:
    # 周期の来る前の回数
    num = p.index(p[-1])
    p = p[num:]

    # 周期
    pn = len(p)-1
    k -= num

    # 回数/周期のあまり
    ans = k%pn
    print(p[ans])
n, q = [int(x) for x in input().split()]
s = input()
td = [input().split() for _ in range(q)]
lo, hi = 0, n-1

for t, d in reversed(td):
    if d == "L" and s[lo] == t:
        lo += 1
    elif d == "R" and s[hi] == t:
        hi -= 1
    if lo >= hi:
        print(0)
        break
else:
    print(hi-lo+1)


### FIXED CODE ###

a,b,c = input().strip().split()

if a == b and b ==c:
    print("Yes")
else:
    print("No")
def main():
  n = int(input())
  A = list(map(int, input().split()))
  
  num = [0] * n
  
  # for i in range(0, n-1):
  #   for k in range(0, len(A)):
  #     if A[k] == i+1:
  #       num[i] += 1
  
  for i in range(0, n-1):
    num[A[i]] += 1
  
  for k in range(1, n+1):    
    print(num[k])
  
main()

### FIXED CODE ###

def main():
  n = int(input())
  A = list(map(int, input().split()))
  
  num = [0] * n + [0]
  
  # for i in range(0, n-1):
  #   for k in range(0, len(A)):
  #     if A[k] == i+1:
  #       num[i] += 1
  
  for i in range(0, n-1):
    num[A[i]] += 1
  
  for k in range(1, n+1):    
    print(num[k])
  
main()
s=input()
t=input()
u=[]
v=[]
s_len=len(s)
for i in range(s_len):
    s_i=s[i]
    t_i=t[i]
    ts=t_i+s_i
    if s_i!=t_i:
        if ts not in u:
            u.append(ts)
    elif s_i not in v:
        v.append(s_i)
u.sort()
u.append("XX")
ans="Yes"
u_len=len(u)
for i in range(u_len):
    if u[i][0] in v or u[i][1] in v:
        ans="No"
        break
    elif u[i][0]==u[i+1][0] and u[i][1]!=u[i+1][1]:
        ans="No"
        break       
print(ans)

### FIXED CODE ###

from operator import itemgetter
s=input()
t=input()
u=[]
v=[]
s_len=len(s)
for i in range(s_len):
    s_i=s[i]
    t_i=t[i]
    ts=t_i+s_i
    if s_i!=t_i:
        if ts not in u:
            u.append(ts)
    elif s_i not in v:
        v.append(s_i)
u_len=len(u)
ans="Yes"
if u_len!=0:
    u1=sorted(u)
    u1.append("XX")
    for i in range(u_len):
        if u1[i][0] in v or u1[i][1] in v:
            ans="No"
            break
        elif u1[i][0]==u1[i+1][0] and u1[i][1]!=u1[i+1][1]:
            ans="No"
            break
    if ans=="Yes":
        u2=sorted(u,key=itemgetter(1))
        u2.append("XX")
        for i in range(u_len):
            if u2[i][0]!=u2[i+1][0] and u2[i][1]==u2[i+1][1]:
                ans="No"
                break
print(ans)
Tmp = []
Tmp = input().rstrip().split(' ')
A = Tmp[0]
Tmp = input().rstrip().split(' ')
B = Tmp[1]
Tmp = input().rstrip().split(' ')
C = Tmp[2]

print('%s%s%s' %(A,B,C))



### FIXED CODE ###

Tmp = []
Tmp = input()
A = Tmp[0]
Tmp = input()
B = Tmp[1]
Tmp = input()
C = Tmp[2]

print('%s%s%s' %(A,B,C))
n = int(input())
from collections import Counter
#a,b = map(int,input().split())
#L = list(map(int,input().split()))
def pr(n):
    L = []
    for i in range(2,int(n**0.5)+1):
        while n % i==0:
            L.append(i)
            n = n//i
    if n != 1:
        L.append(n)
    return L
dic = {1:1,2:1,3:2,4:2,5:2,6:3,7:3,8:3,9:3,10:4,11:4,12:4,13:4,14:4,15:5,16:5,17:5,18:5,19:5,20:5}
L = pr(n)
#print(L)
L = Counter(L)
num = 0
for k,v in L.items():
    num +=dic[v]
print(num)

### FIXED CODE ###

n = int(input())
from collections import Counter
#a,b = map(int,input().split())
#L = list(map(int,input().split()))
def pr(n):
    L = []
    for i in range(2,int(n**0.5)+1):
        while n % i==0:
            L.append(i)
            n = n//i
    if n != 1:
        L.append(n)
    return L
dic = {1:1,2:1,3:2,4:2,5:2,6:3,7:3,8:3,9:3,10:4,11:4,12:4,13:4,14:4,15:5,16:5,17:5,18:5,19:5,20:5,21:6,22:6,23:6,24:6,25:6,27:6,28:7,29:7,30:7,31:7,32:7,33:7,34:7,35:7,36:8,39:8,40:8}
L = pr(n)
#print(L)
L = Counter(L)
num = 0
for k,v in L.items():
    num +=dic[v]
print(num)
S = int(input())
h = int(S // (60*60))
m = int((S % 3600) // 60)
s = int((S % 3600) %60)

print('{0}:{1}:{2}'.format(h.m.s)

### FIXED CODE ###

S = int(input())
h = int(S // (60*60))
m = int(S / 60) % 60
s = S%60

print('{}:{}:{}'.format(h,m,s))
N,A,B=list(map(int,input().split()))
arr=[]

for i in range(N):
    h=int(input())
    arr.append(h)
arr=sorted(arr,reverse=True)
arr=np.array(arr)

max_=arr[0]//B+1
min_=arr[-1]//A

while min_!=max_:
    mid=(max_+min_)//2
    
    tmp=arr-mid*B
    tmp=map(lambda x:math.ceil(x/(A-B)),tmp)
    sum_=sum(list(tmp))
    
    if sum_<=mid:
        max_=mid
    else:
        min_=mid+1

ans=search(min_,max_,A,B,arr)

print(ans)

### FIXED CODE ###

import math
"""
def search(min_,max_,A,B,arr):
#    print(min_,max_)
    if min_==max_:
        return min_
    mid=(max_+min_)//2
    
    tmp=arr-mid*B
    
    if len(tmp)==0:
        return search(min_,mid,A,B,arr)
    
    tmp=map(lambda x:math.ceil(x/(A-B)),tmp)
    sum_=sum(list(tmp))
    if sum_<=mid:
        return search(min_,mid,A,B,arr)
    else:
        return search(mid+1,max_,A,B,arr)

    while True:
        if k<0:
            if mid==min_:
                return max_
            else:
                #failure
                return search(mid,max_,A,B,arr[:L])
        elif len(tmp)==0:
            #success
            return search(min_,mid,A,B,arr)
        x=-tmp[0]
        tmp=np.delete(tmp,0)
        k-=x//(A-B)+(x%(A-B)>0)
"""
        
    
N,A,B=list(map(int,input().split()))
arr=[]

for i in range(N):
    arr.append(int(input()))

max_=max(arr)//B+1
min_=min(arr)//A

d=A-B

while min_!=max_:
    mid=(max_+min_)//2
    
    sum_=0
    for x in arr:
        sum_+=max(0,math.ceil((x-mid*B)/d))
        
    if sum_<=mid:
        max_=mid
    else:
        min_=mid+1

print(min_)
N = int(input())
M = list(map(int,input().split()))for _ in range(N)
sum = o
for i in range(N):
  sum = sum + M[i][1]-M[i][0]+1
print(sum)  

### FIXED CODE ###

N = int(input())
M = [list(map(int,input().split()))for _ in range(N)]
sum = 0
for i in range(N):
  sum = sum + M[i][1]-M[i][0]+1
print(sum)
import math

X = int(input())

def era(n):
    O = [i + 2 for i in range(n-1)]
    P = []
    for i in range(int(math.sqrt(n))):
        P.append(O[0])
        O = [o for o in O if o % P[-1] != 0]
    for o in O:
        P.append(o)
    return P

print(max(P))
for i in range(len(P)):
    if X <= P[i]:
        print(P[i])
        break

### FIXED CODE ###

import math

X = int(input())

def era(n):
    O = [i + 2 for i in range(n-1)]
    P = []
    for i in range(int(math.sqrt(n))):
        P.append(O[0])
        O = [o for o in O if o % P[-1] != 0]
    for o in O:
        P.append(o)
    return P

P = era(2*X)
for i in range(len(P)):
    if X <= P[i]:
        print(P[i])
        break
n, m = map(int,input().split())
if n <= 1 or m <= 1:
    print(0)
else:
    print((n-1) * (m-1)

### FIXED CODE ###

n, m = map(int,input().split())
if n <= 1 or m <= 1:
    print(0)
else:
    print((n-1) * (m-1))
s = input().rstrip()

s1 = "2018" + s[4:] if s.startwith("2017") else s


### FIXED CODE ###

s = input().rstrip()

s1 = "2018" + s[4:] if s.startswith("2017") else s
print(s1)