Harryxun/stf_run huggingface dataset:
N = int(input())
if N%2 == 1:
  ans = (N//2+1)/(N//2)
else:
  ans = 0.5
print(ans)

### FIXED CODE ###

N = int(input())
if N%2 == 1:
  ans = (N//2+1)/N
else:
  ans = 0.5
print(ans)
n=input()
ans=0
for i in range(4):
  if n[i]="2":
    ans+=1
print(ans)

### FIXED CODE ###

n=input()
ans=0
for i in range(4):
  if n[i]=="2":
    ans+=1
print(ans)
from collections import defaultdict
tot = 10**12
n,c = map(int, input().split())
d = [list(map(int, input().split())) for _ in range(n)]
clr = [list(map(int, input().split())) for _ in range(n)]
l = [dict()]*3
for y in range(n):
  for x in range(n):
    l[(x+y)%3][clr[y][x]] += 1
for c1 in range(c):
  for c2 in range(c):
    if c1 == c2:
      continue
    for c3 in range(c):
      if c1==c3 or c2==c3:
        continue
      ctot = 0
      cl = [c1,c2,c3]
      for i in range(3):
        for x in l[i]:
          ctot += d[x-1][c[i]]*l[i][x]
      if tot > ctot:
        tot = ctot
print(tot)
      

### FIXED CODE ###

from collections import defaultdict as ddict
tot = 10**12
n,c = map(int, input().split())
d = [list(map(int, input().split())) for _ in range(c)]
clr = [list(map(int, input().split())) for _ in range(n)]
l = [ddict(int) for _ in range(3)]
for y in range(n):
  for x in range(n):
    l[(x+y)%3][clr[y][x]] += 1
for c1 in range(c):
  for c2 in range(c):
    if c1 == c2:
      continue
    for c3 in range(c):
      if c1==c3 or c2==c3:
        continue
      ctot = 0
      cl = [c1,c2,c3]
      for i in range(3):
        for x in l[i]:
          ctot += d[x-1][cl[i]]*l[i][x]
      if tot > ctot:
        tot = ctot
print(tot)
n, k = map(int, input().split())
a = list(map(int, input().split()))

arr = [-1]*n
next_town = 0
arr[0] = 0
flag = False
for i in range(1, k+1):
    print(next_town+1)
    next_town = a[next_town] - 1
    if arr[next_town] >= 0:
        flag = True
        x = i - arr[next_town]
        l = arr[next_town]
        break
    else:
        arr[next_town] = i
print(flag, x, k%x)
if flag == False:
    print(next_town+1)
else:
    for i in range((k-l)%x):
        print(next_town+1)
        next_town = a[next_town] - 1

    print(next_town+1)

### FIXED CODE ###

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

arr = [-1]*n
next_town = 0
arr[0] = 0
flag = False
for i in range(1, k+1):
    #print(next_town+1)
    next_town = a[next_town] - 1
    if arr[next_town] >= 0:
        flag = True
        x = i - arr[next_town]
        l = arr[next_town]
        break
    else:
        arr[next_town] = i
#print(flag, x, k%x)
if flag == False:
    print(next_town+1)
else:
    for i in range((k-l)%x):
        #print(next_town+1)
        next_town = a[next_town] - 1

    print(next_town+1)
x = int(input())
amax = int(x ** (1/ 5)) + 1
for a in range(amax + 1):
    b5 = a ** 5 - x
    if b5 < 0:
        c = (-b5) ** (1/5)
        if int(c) == c:
            ans = (a, -int(c))
            break
    else:
        c = (b5) ** (1/5)
        if int(c) == c:
            ans = (a, int(c))
            break

print(ans[0], ans[1])

### FIXED CODE ###


def factorize(n):
    ## 素因数分解
    # arr = factorize(20)
    # arr == [[2, 2], [5, 1]]
    
    result = []
    tmp = n
    for k in range(2, int(n ** 0.5) + 1):
        cnt = 0
        while tmp % k == 0:
            cnt += 1
            tmp //= k
        if cnt > 0:
            result.append([k, cnt])
    if tmp != 1:
        result.append([tmp, 1])
    return result

def divisorize(n):
    ## 約数
    # arr = factorize(20)
    # arr == [2, 4, 5, 10, 20]
    f = factorize(n)
    divisors = [1]
    for k in range(len(f)):
        num_divisors = len(divisors)
        for i in range(1, f[k][1] + 1):
            for j in range(num_divisors):
                divisors.append(divisors[j] * f[k][0] ** i)
    return sorted(divisors)

x = int(input())
a = 0
d = divisorize(x)
flg = False
while True:
    for dd in d:
        b = a - dd
#         print(a, dd, b)
        try:
            if a ** 5 - b ** 5 == x:
                flg = True
                break
        except:
            pass
    if flg:
        break
    a += 1
print(a, b)
import collections
N, K, L = map(int, input().split())
road = [{"Connected":[],"seen":False,"set":0} for _ in range(200000)]
rail = [{"Connected":[],"seen":False,"set":0} for _ in range(200000)]

def dfs(graph, v, index): #深さ優先探索
    graph[v]["seen"] = True
    graph[v]["set"] = index
    for next_v in graph[v]["Connected"]:
        if graph[next_v]["seen"]:
            continue
        dfs(graph, next_v, index)

for X in ((road, K), (rail, L)): #結合を入力
    for _ in range(X[1]):
        p, q = map(int, input().split())
        X[0][p-1]["Connected"].append(q-1)
        X[0][q-1]["Connected"].append(p-1)

for X in (road, rail): #探索して連結成分に分解
    set_index = 0
    for v in range(N):
        if X[v]["seen"]:
            continue
        dfs(X, v, set_index)
        set_index += 1
        
List = [(road[i]["set"],rail[i]["set"]) for i in range(N)]
count = collections.Counter(List)
for A in List:
    print(count[A],end=" ")
        


### FIXED CODE ###

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

def fp(x, parentList): #findParent
    if parentList[x] == x:
        return x
    else:
        parentList[x] = fp(parentList[x], parentList)
        return parentList[x]

#各ノードのparentをリストで表現(連結前は自身がparent)
road = [i for i in range(N)]
rail = [i for i in range(N)]

for _ in range(K):
    p, q = map(int, input().split())
    par_p, par_q = fp(p-1, road), fp(q-1, road) #p, qのparent 
    #連結する際、若い番号をparentとする
    if par_p < par_q:
        road[par_q] = par_p
    else:
        road[par_p] = par_q

#railについても同様
for _ in range(L):
    s, t = map(int, input().split())
    par_s, par_t = fp(s-1, rail), fp(t-1, rail)
    if par_s < par_t:
        rail[par_t] = par_s
    else:
        rail[par_s] = par_t

#連結成分の要素をカウント
cnt = {}
for i in range(N):
    key = (fp(i,road),fp(i,rail))
    if key in cnt:
        cnt[key] += 1
    else:
        cnt[key] = 1
#出力
for i in range(N):
    key = (fp(i,road),fp(i,rail))
    ans = cnt[key]
    print(ans, end=" ")
def main():
    N = map(int,input())
    A = list(map(int,input().split(' ')))
    if 0 in A:
        print(0)
        exit(-1)
    MAX = 10**18
    ans = 1
    for a in A:
        ans *= a
    if ans > MAX:
        print(-1)
    else:    
        print(ans)

if __name__ == "__main__":
    main()


### FIXED CODE ###

MAX = 10**18
def main():
    N = map(int,input())
    A = list(map(int,input().split(' ')))
    ans = 1
    if 0 in A:
        print(0)
        exit(0)
    for a in A:
        ans *= a
        if ans > MAX:
            print(-1)
            exit(0)

    print(ans)

if __name__ == "__main__":
    main()
S = int(input())
if S < 3: return 0
MODULO = int(1e9+7)
dp = [0,0,0,1]
for i in range(4,S+1):
  x = dp[i-3] + dp[i-1]
  x %= MODULO
  dp.append(x)
print(dp[-1])

### FIXED CODE ###

S = int(input())
if S < 3:
    print(0)
else:
    MODULO = int(1e9+7)
    dp = [0,0,0,1]
    for i in range(4,S+1):
        x = dp[i-3] + dp[i-1]
        x %= MODULO
        dp.append(x)
    print(dp[-1])
from fractions import gcd

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

forward = []
backward = [0 for x in range(n)]

if n == 2:
    print(max(a[0], a[1]))
    exit(0)

for i in range(n):
    if i == 0:
        forward.append(a[i])
    else:
        forward.append(gcd(forward[i - 1], a[i]))


for i in range(n - 1, -1, -1):
    if i == n - 1:
        backward[i] = a[i]
    else:
        backward[i] = gcd(backward[i + 1], a[i])


ans = 1

for i in range(n):
    if i == 0:
        ans = max(ans, backward[1])
    elif i == n - 1:
        ans = max(ans, forward[n - 2])
    else:
        ans = max(ans, gcd(forward[i - 1], backward[i + 1]))

print(ans)

### FIXED CODE ###

from fractions import gcd

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

forward = []
backward = [0 for x in range(n)]

if n == 2:
    print(max(a[0], a[1]))
    exit(0)

for i in range(n):
    if i == 0:
        forward.append(a[i])
    else:
        forward.append(gcd(forward[i - 1], a[i]))


for i in range(n - 1, -1, -1):
    if i == n - 1:
        backward[i] = a[i]
    else:
        backward[i] = gcd(backward[i + 1], a[i])


ans = 1

for i in range(n):
    if i == 0:
        ans = max(ans, backward[1])
    elif i == n - 1:
        ans = max(ans, forward[n - 2])
    else:
        ans = max(ans, gcd(forward[i - 1], backward[i + 1]))

print(ans)
X=input()
print(min(abs(int(S[i:i+3])-753) for i in range(len(S)-2)))


### FIXED CODE ###

X=input()
print(min(abs(int(X[i:i+3])-753) for i in range(len(X)-2)))
n=int(input())
a=list(map(int,input().split()))
b=list(map(int,input().split()))
c=[]
d=[]
for i in range(n):
  if a[i]>b[i]:
    c.append(a[i]-b[i])
  elif a[i]<b[i]:
    d.append(b[i]-a[i])
c.sort(reverse=True)
if sum(c)<sum(d):
  print(-1)
else:
  ans=0
  while sum(c[:ans])<sum(d):
    ans+=1
print(ans+len(d))

### FIXED CODE ###

n=int(input())
a=list(map(int,input().split()))
b=list(map(int,input().split()))
c=[]
d=[]
for i in range(n):
  if a[i]>b[i]:
    c.append(a[i]-b[i])
  elif a[i]<b[i]:
    d.append(b[i]-a[i])
c.sort(reverse=True)
if sum(c)<sum(d):
  print(-1)
elif sum(c)==sum(d):
  print(len(c)+len(d))
else:
  ans=0
  if len(c)==1:
    print(1+len(d))
  else:
    for i in range(len(c)):
      if sum(c[:i])>=sum(d):
        ans=i
        break
    print(ans+len(d))
# -*- coding: utf-8 -*-
"""
Created on Sat Jul 14 10:14:13 2018
ALDS1_11_D
@author: maezawa
"""
import sys
sys.setrecursionlimit(100000)

n, m = list(map(int, input().split()))
v = [-1 for _ in range(n)]
stack = []
adj = [[] for _ in range(n)]
for i in range(m):
    s, t = list(map(int, input().split()))
    adj[s].append(t)
    adj[t].append(s)
#print(*adj, sep='\n')
def dfs(u, color):
    if v[u] > 0:
        return 0
    v[u] = color
    #print(u, current, stack)
    for k in adj[u]:
        if v[k] > 0:
            continue
        dfs(k, color)
    return 1

color = 1
for start in range(n):
    if dfs(start, color) == 1:
        color += 1
#for i in range(n):        
#    print('color:{} for node:{}'.format(i, v[i]))

q = int(input())
for i in range(q):
    s, t = list(map(int, input().split()))
    if v[s] == v[t]:
        print('yes')
    else:
        print('no')


### FIXED CODE ###

# -*- coding: utf-8 -*-
"""
Created on Sat Jul 14 10:14:13 2018
ALDS1_11_D
@author: maezawa
"""
import sys
sys.setrecursionlimit(1000000)

n, m = list(map(int, input().split()))
v = [-1 for _ in range(n)]
stack = []
adj = [[] for _ in range(n)]
for i in range(m):
    s, t = list(map(int, input().split()))
    adj[s].append(t)
    adj[t].append(s)
#print(*adj, sep='\n')
def dfs(u, color):
    if v[u] > 0:
        return 0
    v[u] = color
    #print(u, current, stack)
    for k in adj[u]:
        if v[k] > 0:
            continue
        dfs(k, color)
    return 1

color = 1
for start in range(n):
    if dfs(start, color) == 1:
        color += 1
#for i in range(n):        
#    print('color:{} for node:{}'.format(i, v[i]))

q = int(input())
for i in range(q):
    s, t = list(map(int, input().split()))
    if v[s] == v[t]:
        print('yes')
    else:
        print('no')
s=input()
import colletions
s=dict(collections.Counter(s))
if len(s)==2:
  flag=True
  for k in s.values():
    if k!=2:
      flag=False
  if flag:
    print("Yes")
  else:
    print("No")
else:
  print("No")
  

### FIXED CODE ###

s=input()
import collections
s=dict(collections.Counter(s))
if len(s)==2:
  flag=True
  for k in s.values():
    if k!=2:
      flag=False
  if flag:
    print("Yes")
  else:
    print("No")
else:
  print("No")
# N = int(input())
# A = [int(x) for x in input().split()]
# V = [[0] * 100 for _ in range(100)]
# MOD = 10 ** 9 + 7
# メモ化再起
from functools import lru_cache
import sys

sys.setrecursionlimit(10000)

N, M = [int(x) for x in input().split()]
A = [int(x) for x in input().split()]
match = [0, 2, 5, 5, 4, 5, 6, 3, 7, 6]



@lru_cache(maxsize=1000000)
def f(n):
    maxval = -float('inf')
    for a in A:
        tmp = n - match[a]
        if tmp == 0:
            maxval = max(maxval, a)
        elif tmp > 0:
            maxval = max(maxval, f2(f(n - match[a]) * 10 + a))
    return maxval

@lru_cache(maxsize=1000000)
def f2(n):
    if n < 0:
        return 0
    n = list(str(n))
    n.sort(reverse=True)
    return int("".join(n))

ans = f(N)
print(ans)


### FIXED CODE ###

# N = int(input())
# A = [int(x) for x in input().split()]
# V = [[0] * 100 for _ in range(100)]
# MOD = 10 ** 9 + 7
# メモ化再起
from functools import lru_cache
import sys

sys.setrecursionlimit(100000000)

N, M = [int(x) for x in input().split()]
A = [int(x) for x in input().split()]
match = [0, 2, 5, 5, 4, 5, 6, 3, 7, 6]



@lru_cache(maxsize=1000000)
def f(n):
    maxval = -float('inf')
    for a in A:
        tmp = n - match[a]
        if tmp == 0:
            maxval = max(maxval, a)
        elif tmp > 0:
            # maxval = max(maxval, f2(f(n - match[a]) * 10 + a))
            maxval = max(maxval, f(n - match[a]) * 10 + a)
    return maxval

@lru_cache(maxsize=1000000)
def f2(n):
    if n < 0:
        return 0
    n = list(str(n))
    n.sort(reverse=True)
    return int("".join(n))

ans = f(N)
print(f2(ans))
n,m=map(int,input().split())

par=[i for i in range(n)]

visited=[False]*n

def find(x):
  if par[x]==x:
    return par[x]
  else:
    par[x]=find(par[x])
    return par[x]


def find2(x):
  visited[x]=True
  if par[x]==x:
    return par[x]
  else:
    par[x]=find2(par[x])
    return par[x]

def union(x,y):
  fx=find(x)
  fy=find(y)
  if fx!=fy:
    par[fx]=fy

ans=-1

for i in range(m):
  x,y,z=map(int,input().split())
  union(x-1,y-1)

ans=1

for i in range(n):
  if visited[i]==False:
    ans+=1
    find2(i)

print(min(ans,len(set(par))))

### FIXED CODE ###

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

par=[i for i in range(n)]
size=[1]*n

def find(x):
  if par[x]==x:
    return x
  else:
    par[x]=find(par[x])
    return par[x]
def union(a,b):
  x=find(a)
  y=find(b)
  if x!=y:
    if size[x]<size[y]:
      par[x]=par[y]
      size[y]+=size[x]
    else: 
      par[y]=par[x]
      size[x]+=size[y]
  else:
    return

for i in range(m):
  x,y,z=map(int,input().split())
  union(x-1,y-1)


ans={find(i) for i in range(n)}

print(len(ans))
A,B,K=map(int,input().split())
a=[]
b=[]
for i in range(A):
  if A%(i+1) == 0:
    a.append(i+1)
for ii in range(B):
  if B%(ii+1) == 0:
    b.append(ii+1)
s=set(a)&set(b)
print(sorted(list(s))[K])

### FIXED CODE ###

A,B,K=map(int,input().split())
a=[]
b=[]
for i in range(A):
  if A%(i+1) == 0:
    a.append(i+1)
for ii in range(B):
  if B%(ii+1) == 0:
    b.append(ii+1)
s=set(a)&set(b)
print(sorted(list(s))[-K])
input = input()
is_good = True
for i, s in enumerate(input):
    if i > 0 and s == input[i-1]:
        is_good = False
        break
    if i < len(input) and s == input[i+1]:
        is_good = False
        break
if is_good:
    print('Good')
else:
    print('Bad')

### FIXED CODE ###

code = input()
is_bad = False
for i, s in enumerate(code):
  if i > 0 and s == code[i-1]:
    print('Bad')
    is_bad = True
    break
  if i < len(s) -1 and s == code[i+1]:
    print('Bad')
    is_bad = True
    break
if not is_bad:
  print('Good')
def main(A,N):
    A = [0] + A
    for a in range(N//2,0,-1):
        #print(inds[ind::ind+1])
        if sum(A[a::a]) %2== 0:
            A[a] = 0
        else:
            A[a] = 1
        
        res = [x for x in range(0,N+1) if A[x]]
    print(len(res))
    print(*res)

N = int(input())
A = [int(x) for x in input().split()]
    
main(A,N)

### FIXED CODE ###

def main(A,N):
    A = [0] + A
    for a in range(N//2,0,-1):
        #print(inds[ind::ind+1])
        if sum(A[a::a]) %2== 0:
            A[a] = 0
        else:
            A[a] = 1
        
    res = [x for x in range(0,N+1) if A[x]]
    print(len(res))
    print(*res)

N = int(input())
A = [int(x) for x in input().split()]
    
main(A,N)
while True:
    n = str(raw_input())
    if n == 0:break
    sum = 0
    for i in n:
        sum += int(i)
    print sum

### FIXED CODE ###

while True:
    n = str(raw_input())
    if n == "0":break
    sum = 0
    for i in n:
        sum += int(i)
    print sum
n,k,s=map(int,input().split())
a=list()
b=[2]*(n-k)+[1]*k
while len(a)<n:
    a+=[1]*(s-1)+[s]
if s!=1:
    print(*a[len(a)-n:])
else:
    print(*b)

### FIXED CODE ###

n,k,s=map(int,input().split())
a=[s]*k
b=[3]*(n-k)+[s]*k
p=max(s//2-1,1)
for i in range(n-k):
    if i%p==0:
        a.append(s-1)
    else:
        a.append(2)
if s!=2 and s!=1:
    print(*a)
else:
    print(*b)
N ,K = map(int, input().split())

A = list(map(int, input().split()))
d = [0] * N

#二分探索
min = 0
max = max(A)

while True:
    X = (min + max)//2
    for i in range(N):
        d[i] = A[i]//X
    if sum(d) <= K:
        max = X
    else:
        min = X
    #print(min, max)
    
    if min + 1 == max:
        print(int(max))
        break


### FIXED CODE ###

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

A = list(map(int, input().split()))
d = [0] * N

#二分探索
min1 = 0
max1 = max(A) + 1

while True:
    X = (min1 + max1)//2
    for i in range(N):
        if A[i] % X == 0:
            d[i] = A[i]//X - 1
        else:
            d[i] = A[i]//X
    if sum(d) <= K:
        max1 = X 
    else:
        min1 = X
    #print(min1, max1)

    if max1 - min1 <= 1:
        print(int(max1))
        break
def main():
    n = int(input())
    inlis = []
    namelis = []
    for i in range(n):
        a, b = map(str, input().split())
        b = int(b)
        inlis.append([a,b])
        namelis.append(a)
    namelis.sort()    
    inlis_so = sorted(inlis)
    anslis = []
    for num in inlis:
        #print(num, num[0], inlis_so, inlis_so.count(num[0]))
        kazu = namelis.count(num[0])
        if kazu == 1:
            anslis.append(inlis_so.index(num))
        else:
            kijun = namelis.index(num[0])+1
            kouho = list(filter(lambda word:True if word[0] == num[0] else False,inlis))
            kouho_so = sorted(kouho, key = lambda x:x[0], reverse = True)
            suujibun = kouho_so.index(num)
            anslis.append(kijun + suujibun)
    for i in range(1, n+1):
        print(anslis.index(i)+1)

    

        
    
if __name__ == "__main__":
    main()


### FIXED CODE ###

def main():
    n = int(input())
    inlis = []
    namelis = []
    for i in range(n):
        a, b = map(str, input().split())
        b = int(b)
        inlis.append([a,b])
        namelis.append(a)
    namelis.sort()    
    inlis_so = sorted(inlis)
    anslis = []
    for num in inlis:
        #print(num, num[0], inlis_so, inlis_so.count(num[0]))
        kazu = namelis.count(num[0])
        if kazu == 1:
            anslis.append(inlis_so.index(num)+1)
        else:
            kijun = namelis.index(num[0]) + 1
            kouho = list(filter(lambda word:True if word[0] == num[0] else False,inlis))
            kouho_so = sorted(kouho, key = lambda x:x[1], reverse = True)
            suujibun = kouho_so.index(num)
            anslis.append(kijun + suujibun)
    for i in range(1, n+1):
        #print(anslis)
        print(anslis.index(i)+1)

    

        
    
if __name__ == "__main__":
    main()
a = int(input())
print(a.replace(1,x),replace(9,1).replace(x,9))

### FIXED CODE ###

a = input()
print(a.replace("1","x").replace("9","1").replace("x","9"))
h, w = map(int, input().split())
s = [input() for _ in range(h)]
box = [(1, 0), (0, 1), (-1, 0), (0, -1)]

black = []
white = []

for i in range(h):
    for j in range(w):
        if s[i][j] == "#":
            black.append((i, j))
        else:
            white.append((i, j))

def check(u, v, p):
    now = p
    for x, y in box:
        if u + x < 0 or u + x >= h or v + y < 0 or v + y >= w:
            continue
        if s[u][v] == "." and s[u+x][v+y] == "#" and p[u+x][v+y] == 0:
            p[u+x][v+y] = 1
            now = check(u+x, v+y, p)

        elif s[u][v] == "#" and s[u+x][v+y] == "." and p[u+x][v+y] == 0:
            p[u+x][v+y] = 1
            now = check(u+x, v+y, p)
    return now

ans = 0
for i, j in black:
    p = [[0]*w for _ in range(h)]
    p[i][j] = 1
    t = check(i, j, p)
    for a, b in white:
        if t[a][b] == 1:
            ans += 1

print(ans)



### FIXED CODE ###

import sys
sys.setrecursionlimit(10**6)

h, w = map(int, input().split())
s = [input() for _ in range(h)]
t = [[None]*w for _ in range(h)]
box = [(1, 0), (0, 1), (-1, 0), (0, -1)]

def dfs(i, j, color):
    if not (0<=i<h and 0<=j<w): return 0, 0
    if s[i][j] == color: return 0, 0
    if t[i][j]: return 0, 0

    t[i][j] = True
    wh, bl = 0, 0
    if s[i][j] == "#":
        bl += 1
    else:
        wh += 1

    for x, y in box:
        tmp1, tmp2 = dfs(i+x, j+y, s[i][j])
        wh, bl = wh+tmp1, bl+tmp2

    return wh, bl

ans = 0
for i in range(h):
    for j in range(w):
        a, b = dfs(i, j, "!")
        ans += a*b
print(ans)
r = int(input())
pi = 3.141592653589
S = r * r * pi
L = 2 * r * pi
print(str(S) + " " + str(L))

### FIXED CODE ###

import math
pi = math.pi
r = float(input())
S = r * r * pi
L = 2 * r * pi
print("{0:.6f}".format(S) + " " + "{0:.6f}".format(L))
S = list(input())
ans = ['k','e','y','e','n','c','e']

for i in range(len(ans)):
  if S[i] == ans[i]:
    S[i] = ans[i] = ''
  else:
    break
S = list(''.join(S))
ans = list(''.join(ans))

if ans != []:
  for i in range(len(ans)):
    for j in range(len(S)):
      if S[j] != ans[i]:
        S[j] = ''
      else:
        break
    else:
      continue
    break
  S = list(''.join(S))

  for i in range(len(ans)):
    if S[i] == ans[i]:
      S[i] = ans[i] = ''
    else:
      break
  S = list(''.join(S))
  ans = list(''.join(ans))

  if ans == [] and S == []:
    print('YES')
  else:
    print('NO')
else:
 print('YES')

### FIXED CODE ###

S = list(input())
ans = ['k','e','y','e','n','c','e']
for i in range(len(S)):
    for j in range(i,len(S)):
        new_str = S[:i] + S[j:]
        if new_str == ans:
            print("YES")
            break
    else:
        continue
    break
else:
    print("NO")
def main():
  n=int(input())
  a=list(map(int, input().split()))
  if 0 in A:
    print(0)
    return
  p=1
  for a in A:
    p=*=a
    if(a>1000000000000000000):
      print(-1)
      return
  print(p)
  


### FIXED CODE ###

def main ():
  N = int(input())
  A = list(map(int,input().split()))
  if 0 in A:
    print (0)
    return
  prod = 1 
  for a in A:
    prod *= a
    if prod > 1000000000000000000:
      print(-1)
      return
  print(prod) 
main ()
n=int(input())
d=sorted(list(map(int,input().split())))
m=int(input())
t=sorted(list(map(int,input().split())))

j=0
for i in range(len(t)):
  if j==len(s):
    print("NO")
    break
  t[i]==s[j]:
    j+=1
else:
  print("YES")
   

### FIXED CODE ###

N=int(input())
a=list(map(int,input().split()))
M=int(input())
t=list(map(int,input().split()))
import collections
ac=collections.Counter(a)
tc=collections.Counter(t)

for task in tc.items():
  if task[0] not in ac:
    print("NO")
    exit(0)
  elif ac[task[0]]<task[1]:
    print("NO")
    exit(0)
print("YES")