Harryxun/stf_run huggingface dataset:
n=int(input())
pr=list(map(int,input().split()))
rate_color=[]
suge=0
for i in range(n):
    if pr[i]>=3200:
        suge+=1
def cl(x):
    if x<=399:
        return [0]
    elif 400<=x<=799:
        return [1]
    elif 800 <=x<=1199:
        return [2]
    elif 1200 <=x<=1599:
        return [3]
    elif 1600<=x<= 1999:
        return [4]
    elif 2000 <=x<=2399:
        return [5]
    elif 2400 <=x<=2799:
        return [6]
    elif 2800 <=x<=3199:
        return [7]

for i in range(n):
    x=pr[i]
    rate_color+=cl(x)
color=list(set(rate_color))
color_num=len(color)


max_num=color_num+suge
if color_num==0:
    mini_num=1
else:
    mini_num=color_num
print(mini_num,max_num)

### FIXED CODE ###

n=int(input())
pr=list(map(int,input().split()))
rate_color=[]
suge=0
for i in range(n):
    if pr[i]>=3200:
        suge+=1
pr=[x for x in pr if x<=3199]

def cl(x):
    if x<=399:
        return [0]
    elif 400<=x<=799:
        return [1]
    elif 800 <=x<=1199:
        return [2]
    elif 1200 <=x<=1599:
        return [3]
    elif 1600<=x<= 1999:
        return [4]
    elif 2000 <=x<=2399:
        return [5]
    elif 2400 <=x<=2799:
        return [6]
    elif 2800 <=x<=3199:
        return [7]

for i in range(len(pr)):
    x=pr[i]
    rate_color+=cl(x)
color=list(set(rate_color))
color_num=len(color)


max_num=color_num+suge
if color_num==0:
    mini_num=1
else:
    mini_num=color_num
print(mini_num,max_num)
H, W = map(int, input().split())
a = []
for i in range(H):
  b = list(input().split())
  a.append(b)
for i in range(2*H):
  for j in range(W):
    if j != W - 1:
      print(a[i//2][j],end="")
    else:
      print(a[i//2][j])

### FIXED CODE ###

H, W = map(int, input().split())
a = []
for i in range(H):
  b = list(input())
  a.append(b)
for i in range(2*H):
  for j in range(W):
    if j != W - 1:
      print(a[i//2][j],end="")
    else:
      print(a[i//2][j])
import math

inf = 10**9+7

def combinations_count(n, r):
    return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

n, k = map(int, input().split())

red = n - k
for i in range(1,k+1):
    if i == 1:
        print(red + 1 -i)
    else:
        print(combinations_count(red+1, i)*2**(k-i)%inf)

### FIXED CODE ###

import math

inf = 10**9+7

def combinations_count(n, r):
    return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

n, k = map(int, input().split())

red = n - k
for i in range(1,k+1):
    if red+1 >= i:
        print(combinations_count(red+1, i)*combinations_count(k-1, i-1)%inf)
    else:
        print(0)
n=int(input())
s = [input() for i in range(n)]
c=0
print(s)
for i in range(n):
   r[i]=(sorted([s[i][j] for j in range(10)]))
   r[i]=''.join(r[i])
for i in range(n-1):
    for j in range(i+1,n):
        if r[i]==r[j]:
            c+=1
print(c)

### FIXED CODE ###

N = int(input())
S = [''.join(sorted(input().rstrip())) for _ in range(N)]
 
from collections import Counter
counter = Counter(S)
 
answer = sum(x*(x-1)//2 for x in counter.values())
print(answer)
import math

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

mod = 10**9 + 7

F = 1
for i in range(2, N + 1):
	F *= i

D = [1]
for i in range(2, N + 1):
	D.append(D[-1] + 1 / i)

L = [0] * N
for i in range(N // 2 + N % 2):
  L[i] = F * (D[-1 - i] + D[i] - 1) % mod
  L[-1 - i] = L[i]

Ans = 0
for i in range(N):
  Ans += math.ceil(L[i] * A[i]) % mod
print(Ans % mod)

### FIXED CODE ###

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

mod = 10**9 + 7

F = 1
for i in range(2, N + 1):
	F = F * i % mod

D = [0]
for i in range(2, N + 1):
	D.append(D[-1] + pow(i, mod - 2, mod))

L = [0] * N
for i in range(N // 2 + N % 2):
  t = round(F * (D[-1 - i] + D[i] + 1)) % mod
  L[i] = t
  L[-1 - i] = t

Ans = 0
for i in range(N):
  Ans += L[i] * A[i] % mod

print(Ans % mod)
N = int(input())
A = int(input())

if N - (N // 500) * 500 <= A:
  print("Yes")
else:
  pritn("No")

### FIXED CODE ###

N = int(input())
A = int(input())

if N - (N // 500) * 500 <= A:
  print("Yes")
else:
  print("No")
s=[input() for _ in range(int(input()))]
t=[input() for _ in range(int(input()))]
l=list(set(n))

print(max(0,max(s.count(l[i])-t.count(l[i]) for i in range(len(l)))))

### FIXED CODE ###

N=int(input())
s=[input() for _ in range(N)]
M=int(input())
t=[input() for _ in range(M)]
def ans1(x):
    return s.count(x)-t.count(x)
ans2=0
ans_1=0
for S in s:
    if ans1(S)>0 and ans1(S)>ans2:
            ans2=ans1(S)
if ans2>=0:
    print(ans2)
else:
    print("0")
import numpy as np
S=input()
Q=int(input())
q=[[0 for i in range(3)] for j in range(Q)]
onecntr=0
for i in range(Q):
    tmp=input().split()
    if(tmp[0]=="1"):
        q[i][0]=1
    else:
        q[i][0]=2
        q[i][1]=int(tmp[1])
        q[i][2]=tmp[2]
    

for i in range(Q):
    if(q[i][0]==1):
        onecntr+=1
    else:
        
        if(onecntr%2==0):
            if(q[i][1]==1):
                S=q[i][2]+S
            else:
                S=S+q[i][2]
        else:
            if(q[i][1]==2):
                S=q[i][2]+S
            else:
                S=S+q[i][2]
        onecntr=0
    
if(onecntr%2==1):
    S=S[::-1]

print(S)

### FIXED CODE ###

S=input()
cntr=0
if(S=="AAA" or S=="BBB"):
    print("No")
else:
    print("Yes")
#-*- coding:utf-8 -*-

while 1:
    n = int(raw_input())
    if not n:
        break
    length = n*n+1
    columns = []
    for i in range(n):
        columns.append([])
    rows = [0]*(length) #列の最小値となっている数
    for i in range(n):
        row = [int(r) for r in raw_input().split(" ")]
        rows[min(row)] = 1
        for i in range(n):
            columns[i].append(row[i])

    result = 0
    for c in columns:
        if rows[max(c)]:
            result = max(c)
            break

    print result

### FIXED CODE ###

#-*- coding:utf-8 -*-

while 1:
    n = int(raw_input())
    if not n:
        break
    columns = []
    for i in range(n):
        columns.append([])
    rows = []
    for i in range(n):
        row = [int(r) for r in raw_input().split(" ")]
        rows.append(min(row))
        for i in range(n):
            columns[i].append(row[i])

    result = 0
    for c in columns:
        if max(c) in rows:
            result = max(c)
            break

    print result
def main():
  _max = max
  h, w = map(int, input().split())
  s = [input() + '#' for _ in range(h)]
  s.append('#' * (w + 1))

  rt = [[-1] * w for _ in range(h + 1)]

  tstart = [-1] * (w + 1)
  for i in range(h + 1):
    si = s[i]
    rti = rt[i]
    ystart = -1
    for j in range(w + 1):
      tj = tstart[j]
      if si[j] == '#':
        if ystart != -1:
          jy = j - ystart
          for k in range(ystart, j):
            rti[k] += jy
          ystart = -1
        if tj != -1:
          itj = i - tj
          for k in range(tj, i):
            rt[k][j] += itj
          tstart[j] = -1
      else:
        if ystart == -1:
          ystart = j
        if tj == -1:
          tstart[j] = i

  print(_max(sum(rt)))

main()

### FIXED CODE ###

h, w = map(int, input().split())
s = [input() + '#' for _ in range(h)]
s.append('#' * w)

yoko = [[0] * w for _ in range(h)]
for i in range(h):
  if s[i][0] == '.':
    start = 0
  else:
    start = -1
  for j in range(1, w + 1):
    if s[i][j] == '#':
      if start != -1:
        for k in range(start, j):
          yoko[i][k] = j - start
        start = -1
    else:
      if start == -1:
        start = j

tate = [[0] * w for _ in range(h)]
for i in range(w):
  if s[0][i] == '.':
    start = 0
  else:
    start = -1
  for j in range(1, h + 1):
    if s[j][i] == '#':
      if start != -1:
        for k in range(start, j):
          tate[k][i] = j - start
        start = -1
    else:
      if start == -1:
        start = j
result = 0
for i in range(h):
  for j in range(w):
    t = yoko[i][j] + tate[i][j] - 1
    if t > result:
      result = t

print(result)
from heapq import *
def abc144c():
  n,k=map(int,input().split())
  a=sorted(list(map(int,input().split())))
  f=sorted(list(map(int,input().split())))[::-1]
  q=[] 
  for i,j in zip(a,f):
    heappush(q,(-i*j,j))
  for i in range(k):
    tmp,key=heappop(q)
    heappush(q,(tmp+key,key))
  ans,key=-heappop(q)
  return ans
print(abc144c())


### FIXED CODE ###

n,k=map(int,input().split())
abilities=sorted(list(map(int,input().split())))
foods=sorted(list(map(int,input().split())),reverse=True)

if sum(abilities)<=k:
  print(0)
  exit()
  
def check(score):
  ret=0
  for a,f in zip(abilities,foods):
    ret+=max(0,(a*f-score+f-1)//f)
  return ret<=k

ok=10**12+1
ng=0
for _ in range(50):
  mid=(ok+ng)//2
  if check(mid):
    ok=mid
  else:
    ng=mid
print(ok)
tax = [int(n) for n in input().split()]

max_8tax = (tax[0]+1) / .08
min_8tax = int((tax[0]) / .08)
max_10tax = int((tax[1]+1) / .1) - 1
min_10tax = int((tax[1]) / .1)

r = -1

#print(max_8tax, min_8tax)
#print(max_10tax, min_10tax)

for i in range(min_10tax, max_10tax):
    if min_8tax <= i and i <= max_8tax:
        r = i
        break

print(r)

### FIXED CODE ###

s = input()

if s == 'AAA' or s == 'BBB':
  print('No')
else:
  print('Yes')
import sys
sys.setrecursionlimit(10**6)


def f(n):
    if n == 0:
        return 1
    p = n % (bin(n).count('1'))
    return f(p) + 1


def main(input, print):
    N = int(input())
    X = list(map(int, list(input())))
    ans = [0] * N

    pcnt = 0
    for i in range(N):
        if X[i] == 1:
            pcnt += 1
    for is_up in range(2):
        current_pcnt = pcnt
        if is_up:
            current_pcnt -= 1
        else:
            current_pcnt += 1
        if current_pcnt <= 0:
            continue
        total = 0
        for i in range(N):
            total = (total*2) % current_pcnt
            total += X[i]
        current_mask = 1
        for i in reversed(range(N)):
            if(X[i] == is_up):
                current_total = total
                if is_up:
                    current_total = (current_total-current_mask+current_pcnt) % current_pcnt
                else:
                    current_total = (current_total+current_mask) % current_pcnt
                ans[i] = f(current_total)
            current_mask = current_mask * 2 % current_pcnt

    for i in range(N):
        print(ans[i])


if __name__ == '__main__':
    main(sys.stdin.readline, print)


### FIXED CODE ###

import sys
sys.setrecursionlimit(10**6)


def f(n):
    if n == 0:
        return 1
    p = n % (bin(n).count('1'))
    return f(p) + 1


def main(input, print):
    N = int(input())
    X = list(map(int, list(input().strip())))
    ans = [0] * N

    pcnt = 0
    for i in range(N):
        if X[i] == 1:
            pcnt += 1
    for is_up in range(2):
        current_pcnt = pcnt
        if is_up:
            current_pcnt -= 1
        else:
            current_pcnt += 1
        if current_pcnt <= 0:
            continue
        total = 0
        for i in range(N):
            total = (total*2) % current_pcnt
            total += X[i]
        current_mask = 1
        for i in reversed(range(N)):
            if(X[i] == is_up):
                current_total = total
                if is_up:
                    current_total = (current_total-current_mask+current_pcnt) % current_pcnt
                else:
                    current_total = (current_total+current_mask) % current_pcnt
                ans[i] = f(current_total)
            current_mask = current_mask * 2 % current_pcnt

    for i in range(N):
        print(ans[i])


if __name__ == '__main__':
    main(sys.stdin.readline, print)
a,b[int(x) for x in input().split()]
print(a*b,(a+b)*2)

### FIXED CODE ###

a,b=[int(x) for x in input().split()]
print(a*b,(a+b)*2)
from math import ceil
N, u, v = map(lambda x: int(x)-1, input().split())
N += 1
edges = [list(map(lambda x:int(x)-1, input().split())) for _ in range(N-1)]
adj = [[] for _ in range(N)]
for a, b in edges:
    adj[a].append(b)
    adj[b].append(a)

# bfs from v
dist_from_v = [-1]*N
dist_from_v[v] = 0
Q = [v]
while Q:
    tmp = []
    for cur in Q:
        for next in adj[cur]:
            if dist_from_v[next] == -1:
                dist_from_v[next] = dist_from_v[cur]+1
                tmp.append(next)
    Q = tmp

dst_u = -1
# bfs from u
dist_from_u = [-1]*N
dist_from_u[u] = 0
Q = [u]
while Q:
    tmp = []
    for cur in Q:
        for next in adj[cur]:
            if dist_from_u[next] == -1:
                if dist_from_u[cur]+1 >= dist_from_v[next]:
                    # print("update")
                    cut = (cur, next)
                else:
                    dist_from_u[next] = dist_from_u[cur]+1
                    tmp.append(next)
    Q = tmp


dst_u = dist_from_u.index(max(dist_from_u))
dist_u_dst = max(dist_from_u)
dist_v_dst = dist_from_v[dst_u]
# print(dist_from_v)
# print(dist_from_u)
# print(cut)
assert dist_u_dst < dist_v_dst

if dist_v_dst % 2 == 0:
    ans = dist_u_dst+(dist_v_dst-dist_u_dst)//2
else:
    ans = dist_u_dst+dist_v_dst-dist_u_dst
print(ans)


### FIXED CODE ###

def solve():
    _N = int(input())
    N = _N
    ans = 0
    if N % 2 == 0:
        div = 10
        while N // div > 0:
            ans += N//div
            div *= 5
    print(ans)


solve()
N, A, B = map(int, input().split())
ans = N // (A + B) * A
rem = N % (A + B)
ans += min(rem, A)
print(ans)

### FIXED CODE ###

N, A, B = map(int, input().split())
ans = N // (A + B) * A
rem = N % (A + B)
ans += min(rem, A)
print(ans)
l = []
while True:
    x = input()
    if x == 0:
        break
    l.append(x)
    y = l.index(x) + 1
    print('Case {}: {}'.format(y,x))
    y + 1    

### FIXED CODE ###

l = []
y = 1
while True:
    x = int(input())
    if x == 0:
        break
    l.append(x)
    print('Case {}: {}'.format(y,x))
    y += 1
s=input()

if s='SUN':
    ans='7'
elif s='MON':
    ans='6'
elif s='TUE':
    ans='5'
elif s='WED':
    ans='4'
elif s='THU':
    ans='3'
elif s='FRI':
    ans='2'
elif s='SAT':
    ans='1'

print(ans)

### FIXED CODE ###

s=input()

if s=='SUN':
    ans='7'
elif s=='MON':
    ans='6'
elif s=='TUE':
    ans='5'
elif s=='WED':
    ans='4'
elif s=='THU':
    ans='3'
elif s=='FRI':
    ans='2'
elif s=='SAT':
    ans='1'

print(ans)
import sys
import math

def is_capable(n, k, w, P):
    track = 0
    cnt = 0
    i = 0

    while cnt < k:
        if i == n:
            return True

        if track + w[i] > P:
            track = 0
            cnt += 1
        else:
            track += w[i]
            i += 1

    return False
    pass

# ??\?????¨
n, k = map(int, sys.stdin.readline().split())
w = []
for i in range(n):
    w.append(int(sys.stdin.readline().strip()))

'''
print(n,k)
print(w)
'''

# ????????¨

if k == 1:
    ans = sum(w)
    print(ans)
elif n == 1:
    ans = w[0]
    print(ans)
else:
    max_p = sum(w)
    min_p = math.ceil(max_p / k) - 1

    capable = [None] * (max_p - min_p + 1)
    capable[0] = False
    capable[-1] = True

    bottom = 0
    top = len(capable)

    while bottom < top:
        mid = (bottom + top) // 2

        if capable[mid] is None:
            capable[mid] = is_capable(n, k, w, min_p + mid)

        if capable[mid] == True:
            if capable[mid - 1] is None:
                capable[mid - 1] = is_capable(n, k, w, min_p + mid - 1)

            if capable[mid - 1] == False:
                bnd = mid
                break
            else:
                top = mid - 1
        elif capable[mid] == False:
            if capable[mid + 1] is None:
                capable[mid + 1] = is_capable(n, k, w, min_p + mid + 1)

            if capable[mid + 1] == True:
                bnd = mid + 1
                break
            else:
                bottom = mid + 2

    ans = min_p + bnd

    print(ans)
    # print(capable)

### FIXED CODE ###

import sys
import math

def is_capable(n, k, w, P):
    track = 0
    cnt = 0
    i = 0

    while cnt < k:
        if i == n:
            return i

        if track + w[i] > P:
            track = 0
            cnt += 1
        else:
            track += w[i]
            i += 1

    return i
    pass

# ??\?????¨
n, k = map(int, sys.stdin.readline().split())
w = []
for i in range(n):
    w.append(int(sys.stdin.readline().strip()))

'''
print(n,k)
print(w)
'''

# ????????¨

if k == 1:
    ans = sum(w)
    print(ans)
elif n == 1:
    ans = w[0]
    print(ans)
else:
    max_p = sum(w)
    min_p = math.ceil(max_p / k) - 1

    # print(max_p, min_p)
    # sys.exit(0)
    
    bottom = min_p
    top = max_p

    while top - bottom > 1:
        mid = (bottom + top) // 2

        if is_capable(n, k, w, mid) == n:
            top = mid
        else:
            bottom = mid

    print(top)
import numpy as np

N, M, X = list(map(int, input().split()))
a = np.zeros((M, N))
C = np.zeros(N)
for i in range(N):
    tmp = list(map(int, input().split()))
    C[i] += tmp[0]
    a[i] += tmp[1:]

a = a.reshape(M, N)

answer_price = 2**10

for i in range(1 << N):
    tmp = np.zeros(M)
    cost = 0
    for j in range(N):
        if i % 2 == 1:
            tmp += a[j]
            cost += C[j]
        i = i >> 1
    if all(tmp >= X) and cost < answer_price:
        answer_price = cost
        
if answer_price == 2**10:
    print("-1")
else:
    print(int(answer_price))

### FIXED CODE ###

import numpy as np

N, M, X = list(map(int, input().split()))
a = np.zeros((N, M))
C = np.zeros(N)
for i in range(N):
    tmp = list(map(int, input().split()))
    C[i] += tmp[0]
    a[i] += tmp[1:]
    
answer_price = 10**10

for i in range(1 << N):
    tmp = np.zeros(M)
    cost = 0
    for j in range(N):
        if i % 2 == 1:
            tmp += a[j]
            cost += C[j]
        i = i >> 1

    if all(tmp >= X) and (cost < answer_price):
        answer_price = cost
        
if answer_price == 10**10:
    print("-1")
else:
    print(int(answer_price))
#入出力
K,N = map(int, input("K,N:").split())
An_list = np.array(input("An:").split(), dtype=int)

# ここの距離を求める
An_delta_list = np.array([], dtype=int)

# 差のリストをつくる
for i in range(len(An_list)-1):
    An_delta_list = np.append(An_delta_list, An_list[i+1] -An_list[i])
An_delta_list = np.append(An_delta_list, K - An_list[-1])

# 差が最大の部分を見つける
An_delta_max = np.max(An_delta_list)
result = np.sum(An_delta_list) - An_delta_max


print(result)

### FIXED CODE ###

import numpy as np

K,N = map(int, input().split())
An_list = np.array(input().split(), dtype=int)

An_delta_list = np.diff(An_list)
An_delta_list = np.append(An_delta_list, (K - An_list[-1])+An_list[0])
An_delta_max = np.max(An_delta_list)
result = np.sum(An_delta_list) - An_delta_max
print(result)
l = input()
m = input()
z = l.split(' ')
M = int(z[1])
N = int(z[0])
C = (1/(4*M))*N
F = m.split(' ')
X = []
print("No")

for item in F:
	votes = int(item)
	X.append(votes)
X.sort(reverse = True)
for i in range(M):
	if X[i]<C:
		print("No")
		return
print("Yes")


### FIXED CODE ###

l = input().split(' ')

print(str(l[2])+' '+str(l[0])+' '+str(l[1]))
import sys


def test():
    n, m, x = map(int, input().split())
    books = [list(map(int, input().split())) for _ in range(n)]
    ans = 12345678
    is_ok = False
    for i in range(2 ** n):
        cost = 0
        level = [0] * (m)
        for j in range(n):
            if ((i >> j) & 1):
                cost += books[j][0]
                for k in range(m):
                    level[k] += books[j][k+1]

        if min(*level) >= x:
            ans = min(ans, cost)
            is_ok = True

    if is_ok:
        print(ans)
    else:
        print(-1)


if __name__ == "__main__":
    test()


### FIXED CODE ###

def bit():
    n, m, x = map(int, input().split())
    books = [list(map(int, input().split())) for _ in range(n)]
    ans = 99999999999999999
    for i in range(2 ** n):
        cost = 0
        level = [0] * (m)
        for j in range(n):
            if ((i >> j) & 1):
                cost += books[j][0]
                for k in range(m):
                    level[k] += books[j][k+1]

        if level and min(level) >= x:
            ans = min(ans, cost)

    if ans == 99999999999999999:
        print(-1)
    else:
        print(ans)


if __name__ == "__main__":
    bit()
#!/usr/bin/env python3

import sys

def main():
    n = int(input())
    imax = None
    dmax = 0
    for i in range(2, n + 1):
        print("? {} {}".format(1, i))
        sys.stdout.flush()
        dist = int(input())
        if dist > dmax:
            dmax = dist
            imax = i
    imax2 = None
    dmax2 = 0
    for i in range(1, n + 1):
        if i == imax2:
            continue
        print("? {} {}".format(imax, i))
        sys.stdout.flush()
        dist = int(input())
        if dist > dmax2:
            dmax2 = dist
            imax2 = i
    print("! {} {}".format(imax, imax2))

if __name__ == "__main__":
    main()


### FIXED CODE ###

#!/usr/bin/env python3

def fact_of_two(i):
    for j in range(10000):
        if i % (2 ** j) != 0:
            break
    assert j >= 1
    return j - 1

n = int(input())
ai = list(map(int, input().split()))
assert len(ai) == n

mi = 999999
for a in ai:
    mi = min(mi, fact_of_two(a))

print(mi)
N, A = map(int, input().split())
x = list(map(int, input().split()))
MAX_J = sum(x)
dp = [[0] * (MAX_J+1) for i in range(N+1)]
dp[0][0] = 1
for n in range(N):
    for i in range(N)[::-1]:
        for j in range(MAX_J-x[n]+1)[::-1]:
            dp[i+1][j+x[n]] += dp[i][j]
ans = 0
for i in range(1, N+1):
    ans += dp[i][A * i]
print(ans)


### FIXED CODE ###

N, A = map(int, input().split())
x = list(map(int, input().split()))
MAX_J = sum(x)
dp = [[0] * (MAX_J+1) for i in range(N+1)]
dp[0][0] = 1
for n in range(N):
    for i in range(N)[::-1]:
        for j in range(MAX_J-x[n]+1)[::-1]:
            dp[i+1][j+x[n]] += dp[i][j]
ans = 0
for i in range(1, N+1):
    if A * i <= MAX_J:
        ans += dp[i][A * i]
print(ans)
cc = collections.Counter(raw_input())
print 'Yes' if len(cc) == 2 and cc.values() ==[2,2] else 'No'

### FIXED CODE ###

import collections
cc = collections.Counter(raw_input())
print 'Yes' if len(cc) == 2 and cc.values() ==[2,2] else 'No'
s = input()
if(s.length() != 6):
  print("No")

if(s[2] == s[3] && s[4] == s[5]):
  print("Yes")
else:
  print("No")

### FIXED CODE ###

s = input()
 
if(s[2] == s[3] and s[4] == s[5]):
  print("Yes")
else:
  print("No")
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-

n=input()
x=len(n)
k=int(input())
l=[int(i) for i in n]
dp1=[[0]*(k+2) for i in range(x+1)]
dp2=[[0]*(k+2) for i in range(x+1)]
dp2[0][0]=1
dp2[1][0]=1
dp2[1][1]=l[0]-1
for i in range(1,k+1):
    dp1[i][i]=1
for i in range(k,x+1):
    dp1[i][k]=1
for i in range(2,x+1):
    for j in range(k+1):
        if j==0:
            dp2[i][j]=1
        elif j<=i:
            dp2[i][j]+=max(0,l[i-1]-1)
            dp2[i][j]+=((dp2[i-1][j])+(dp2[i-1][j-1]*9))
            #print(i,j,dp2[i-1][j],dp2[i-1][j-1]*9)
print(dp1[x][k]+dp2[x][k])

### FIXED CODE ###

n="0"+input()
x=len(n)
k=int(input())
l=[int(i) for i in n]

## dp1:top   dp2:under
dp1=[[0]*(k+2) for i in range(x)]
dp2=[[0]*(k+2) for i in range(x)]

dp1[0][0]=1
dp1[0][1]=0
dp2[0][0]=0
dp2[0][1]=0

cnt=0
for i in range(1,x):
    if l[i]>0:
        cnt+=1
    if cnt<=k:
        dp1[i][cnt]=1
for i in range(1,x):
    for j in range(k+1):
        if j==0:
            dp2[i][0]=1
        else:
            if l[i]==0: dp2[i][j]=(dp2[i-1][j-1]*9)+(dp2[i-1][j])+(dp1[i-1][j-1]*max(0,l[i]-1))
            else: dp2[i][j]=(dp2[i-1][j-1]*9)+(dp2[i-1][j])+(dp1[i-1][j-1]*max(0,l[i]-1))+(dp1[i-1][j])
print(dp1[-1][-2]+dp2[-1][-2])
a,b = map(int, input().split())
 
if a >= 13:
  print(b)
elif 6 <= a && a <= 12:
  print(int(b/2))
else:
  print(0)

### FIXED CODE ###

a,b = map(int, input().split())
 
if a >= 13:
  print(b)
elif 6 <= a and a <= 12:
  print(int(b/2))
else:
  print(0)
n = int(input())
botan = [int(input()) for i in range(n)]
light = 1 # 1番目のボタンが初め光ってる
count = 1
exi = [1]

if 2 in botan:

    while True:
    light = botan[light - 1]
    if light in exi:
        print(-1)
        exit()
    exi.append(light)
    
    if 2 in exi:
        print(count)
        exit()
    count += 1

else:
    print(-1)

### FIXED CODE ###

n = int(input())
botan = [int(input()) for i in range(n)]
light = 0 # 1番目のボタンが初め光ってる
count = 0

for i in range(n):
    light = botan[light] - 1
    if light == 1:
        break
    
if i == n - 1:
    print(-1)
else:
    print(i + 1)