peterverebics/CodeNet_Python_428 huggingface dataset:
# Judge status: Accepted
n,k = map(int,input().split())
r,s,p = map(int,input().split())
t = list(input())

for i in range(k,n):
    if t[i] == t[i-k]:
        t[i] = "0"

ans = [0] * n

for i in range(n):
    if t[i] == "r":
        ans[i] = p
    elif t[i] == "s":
        ans[i] = r
    elif t[i] == "p":
        ans[i] = s

print(sum(ans))
# Judge status: Accepted
N,A,B,C,D = map(int, input().split())
S = input()

if "##" in S[A-1:max(C-1,D-1)]:
    print("No")
elif D < C and ("..." not in S[B-2:D+1]):
    print("No")
else:
    print("Yes")
# Judge status: Wrong Answer
n,k = map(int, input().split())
s = [1]*n
for i in range(k):  
    d = int(input())
    a = map(int, input().split())
    for i in range(d):
        if s[i] == 1:s[i] = 0
print(sum(s))
# Judge status: Wrong Answer
a,b = map(int,input().split())
if a==b:
  print('Draw')
elif a==1 or a>b:
  print('Alice')
elif b==1 or b>a:
  print('Bob')
# Judge status: Accepted
a,b = map(int,input().split())
c = list(map(int,input().split()))
c.sort()
ans = 0
for i in range(b):
    ans += c[i]
print(ans)
# Judge status: Wrong Answer
from collections import Counter
x=[]
y=[]
n,m=list(map(int,input().split()))
h=list(map(int,input().split()))


for i in range(m):
    a,b=list(map(int,input().split()))
    x.append(a)
    x.append(b)
    if h[a-1]>h[b-1]:
        y.append(a)
    elif h[a-1]<h[b-1]:
        y.append(b)


xx=Counter(x)
yy=Counter(y)

num=n-len(set(xx))
num2=len(set(yy))
print(num+num2) #孤立を考える
# Judge status: Wrong Answer
H, A = map(int, input().split(" "))
print(H//A + (1 if H%A ==0 else 0))
# Judge status: Accepted
import collections
n = int(input())
a = list(map(str, input().split()))

b = collections.deque()

for i in range(n):
    if i % 2 == 0:
        b.append(a[i])
    else:
        b.appendleft(a[i])
if n % 2 == 0:
    print(" ".join(b))
else:
    b = reversed(b)
    print(" ".join(b))
# Judge status: Accepted
def main():
    n, a, b = map(int, input().split())

    if (b - a) % 2 == 0:
        ans = (b - a) // 2
    else:
        if b - 1 < n - a:
            g = (b - a + 1) // 2
            ans = a + g - 1
        else:
            g = (2 * n + a - b + 1) // 2
            ans = 2 * n - b - g + 1
    
    print(ans)


if __name__ == "__main__":
    main()
# Judge status: Wrong Answer
import numpy as np
import math

n,k = str(input()).split()
ans = np.log(int(n))/np.log(int(k))
print(math.ceil(ans))
# Judge status: Accepted
n, k = map(int, input().split())
if n%k!=0:
    print(1)
else:
    print(0)
# Judge status: Wrong Answer
a, b, c = [int(i) for i in input().split()]

cnt = 0
history = set()
while True:
  print(a, b, c, "-", cnt, history)
  if (a, b, c) in history:
    print(-1)
    exit(0)
  if a % 2 == 1 or b % 2 == 1 or c % 2 == 1:
    print(cnt)
    exit(0)
  a, b, c = sorted([a, b, c])
  history.add((a, b, c))
  na = b // 2 + c // 2
  nb = a // 2 + c // 2
  nc = a // 2 + b // 2
  a = na
  b = nb 
  c = nc
  cnt += 1
# Judge status: Accepted
N = int(input())
S = input()

MOD = 1000000007

d = {}
for c in S:
    if c in d:
        d[c] += 1
    else:
        d[c] = 1

result = 1
for x in d.values():
    result *= x + 1
    result %= MOD
result += MOD - 1
result %= MOD

print(result)
# Judge status: Accepted
import math
 
X = int(input())
 
for i in range(X, 100004):
  f = True
  for j in range(2, int(math.sqrt(X))+1):
    if i % j == 0:
      f = False
      break
  if f:
    print(i)
    break
# Judge status: Accepted
from math import ceil
N=int(input())
a=list(map(int,input().split()))
c=0
e=0
d=0

for i in range(N):
    if a[i]%4==0:
        c=c+1
    if a[i]%2==1:
        e=e+1
    else:
        d=d+1

if (d-c)==0:
    if e<=c+1:
        print("Yes")
    else:
        print("No")
else:
    if e+1<=c+1:
        print("Yes")
    else:
        print("No")
# Judge status: Wrong Answer
import math
a,b=input().split()
x=int(a+b)
if math.sqrt(x).is_integer ==True:
	print('Yes')
else:
	print('No')
# Judge status: Accepted
k = int(input())
s = input()

# print(len(s))

if len(s) <= k:
    print(s)
else:
    print(s[0:k] + '...')
# Judge status: Accepted
a,b,c=map(int,input().split())
if (a!=b and b!=c and c!=a) or (a==b and b==c):
  print('No')
else:
  print('Yes')
# Judge status: Accepted
s = str(input())
t = str(input())
w = []
for i in range(len(s)-len(t)+1):
    num = 0
    for h in range(len(t)):
        if t[h] == s[i+h]:
            num += 1
    w.append(len(t)-num)
print(min(w))
# Judge status: Accepted
a,b=map(int,input().split())
if  a<=8 and b<=8:
    print('Yay!')
else:
    print(':(')
# Judge status: Accepted
n,k=map(int,input().split())

trick=[True]*n

for i in range(k):
    input()
    a_lis=list(map(int,input().split()))
    for a in a_lis:
        trick[a-1]=False


ans=0
for i in range(n):
    if(trick[i]):
        ans+=1

print(ans)
# Judge status: Accepted
A, B, C = sorted(list(map(int, input().split())))
ans = 0
if A % 2 == B % 2 and A % 2 != C % 2:
    A += 1
    B += 1
    ans += 1
if A % 2 == C % 2 and A % 2 != B % 2:
    A += 1
    C += 1
    ans += 1
if B % 2 == C % 2 and B % 2 != A % 2:
    B += 1
    C += 1
    ans += 1
ans += (C - A) // 2 + (C - B) // 2
print(ans)
# Judge status: Wrong Answer
a = int(input())
b = int(input())
h = int(input())

sum = a + b
print(sum * h /2)
# Judge status: Accepted
N, K = map(int, input().split())
H = list(map(int, input().split()))
H.sort(reverse = True)
if K >= len(H):
    print(0)
else:
    l = H[K:]
    print(sum(l))
# Judge status: Accepted


def luca(n):
  lz=2
  lo=1
  if n==1:
    return 1
  for i in range(n-1):
    
    nl=lz+lo
    lz=lo
    lo=nl

  return nl

print(luca(int(input())))
# Judge status: Accepted
A, B, K = map(int, input().split())

A_after = 0
B_after = 0

if A - K >= 0:
  A_after = A - K
  B_after = B

elif A + B - K >= 0:
  B_after = B - (K - A)
  
print(A_after, B_after)
# Judge status: Accepted
N, M = map(int, input().split())
can = [[] for i in range(N + 1)]
for i in range(M):
  a, b = map(int, input().split())
  x = [a, b]
  if (1 in x) or (N in x):
    can[a].append(b)
    can[b].append(a)


for j in range(len(can[1])):
  k = can[1][j]
  if N in can[k]:
    print("POSSIBLE")
    quit()
    
print("IMPOSSIBLE")
# Judge status: Accepted
import math
n,d = map(int,input().split())
ans = 0
for i in range(n):
    x,y = map(float,input().split())
    if math.sqrt(x*x+y*y)<=d:
        ans+=1
print(ans)
# Judge status: Accepted
a, b = map(int, input().split())
for i in range(1011):
    if int(i * 0.08) == a and int(i * 0.1) == b:
        print(i)
        break
else:
    print(-1)
# Judge status: Accepted
N = int(input())
A = sorted(list(map(int, input().split())))

l = A[-1]
m = A[-1]//2
r = 0
tmp = 0
for i in range(N):
    d = min(abs(l-A[i]), abs(0-A[i]))
    if tmp < d:
        r = A[i]
        tmp = d

print(l, r)
# Judge status: Accepted
n = int(input())
if n < 1000:
    print("ABC")
else:
    print("ABD")
# Judge status: Wrong Answer
a, b = map(int, input().split())
for i in range(10**18):
    if i != a:
        if i%8 == 0 and i%6 != 0:
            print(i)
            break
    if a == b:
        print(-1)
        break
# Judge status: Accepted
N, M = map(int, input().split(' '))
nums = [1 for _ in range(N)]
has_balls = [False for _ in range(N)]
has_balls[0] = True

for _ in range(M):
    x, y = map(int, input().split(' '))
    x -= 1
    y -= 1

    if has_balls[x]:
        has_balls[y] = True

    nums[y] += 1
    nums[x] -= 1
    if not nums[x]:
        has_balls[x] = False



ret = 0
for h in has_balls:
    if h:
        ret += 1

print(ret)
# Judge status: Accepted
n = int(input())
al = list(map(int,input().split()))

ansl = [0] * 9

for a in al:
    k = min(a // 400, 8)
    ansl[k] += 1

min_ans = 0
for a in ansl[:8]:
    if a > 0:
        min_ans += 1

max_ans = min_ans
if ansl[-1] > 0:
    if min_ans == 0:
        min_ans += 1
        max_ans += ansl[-1]
    else:
        max_ans = min_ans + ansl[-1]

print(min_ans, max_ans)
# Judge status: Wrong Answer
import numpy as np
INF = 2**60
N, W = map(int, input().split())
wv = [map(int, input().split()) for i in range(N)]
dp = np.full((N+1, W+1), -INF, dtype = np.int)
dp[0][0] = 0 # 初期条件
for i, (w, v) in enumerate(wv):
    dp[i+1] = np.maximum(dp[i+1], dp[i])
    dp[i+1][w:] = np.maximum(dp[i+1][w:], dp[i][:-w] + v)
print(np.max(dp[N][:W]))
# Judge status: Accepted
n=int(input())
A=0
W=0
T=0
R=0
for i in range(n):
	a=input()
	if a=='AC':
		A+=1
	if a=='WA':
		W+=1
	if a=='TLE':
		T+=1
	if a=='RE':
		R+=1
print('AC x '+str(A))
print('WA x '+str(W))
print('TLE x '+str(T))
print('RE x '+str(R))
# Judge status: Accepted
a, b = map(int, input().split())
if a ==1:
  a += 100
if b ==1:
  b += 100
if a == b :
  print('Draw')
elif a > b :
  print('Alice')
else:
  print('Bob')
# Judge status: Wrong Answer
S = input()
year_list = ["01","02","03","04","04","05","06","07","08","09","10","11","12"]

if S[0:2] in year_list:
    if S[2:4] in year_list:
        print("AMBIGUOUS")
    else:
        print("YYMM")
else:
    if S[2:4] in year_list:
        print("MMYY")
    else:
        print("NA")
# Judge status: Accepted
s = input()
n = len(s)
ans = 1000

for i in range(n-2):
  c = int(s[i])*100+int(s[i+1])*10+int(s[i+2])
  ans = min(ans,abs(753-c))
  
print(ans)
# Judge status: Wrong Answer
n=int(input())

print("Yes"if n%4==0 or n%7==0 or n%11==0 else "No")
# Judge status: Accepted
# input
A, B, C = map(int, input().split())

# check
max_cnt = B // A
if max_cnt > C:
    print(C)
else:
    print(max_cnt)
# Judge status: Accepted
#abc150d
def gcd(a,b):
 while b:
  a,b=b,a%b
 return a
def lcm(a,b):
 return a/gcd(a,b)*b
import sys
n,m=map(int,raw_input().split())
a=map(int,raw_input().split())
LCM=1
for i in range(n):
 LCM=lcm(LCM,a[i])
for i in range(n):
 if LCM/a[i]%2==0:
  print 0
  sys.exit()
res=(m/(LCM/2)+1)/2
print res
# Judge status: Wrong Answer
l = int(input())
a = 0

for i in range(l):
    for j in range(l-i):
        k = l-(i+j)
        #print(i,j,k)
        a = i*j*k if i*j*k > a else a

print(float(a))
# Judge status: Wrong Answer
a,b,c,d = map(int,input().split())

xp = True if a + b > 0 else False
yp = True if c + d > 0 else False

if xp:
  if yp:
    ans = b * c
  else:
    ans = a * d
else:
  if yp:
    ans = b * c
  else:
    ans = b * d

print(ans)
# Judge status: Accepted
def resolve():
    N,x = map(int,input().split())
    A = list(map(int,input().split()))
    A.sort()
    Acouont = 0
    ans = 0
    if sum(A) < x:
        print(N-1)
    else:
        for i in range(N):
            Acouont = Acouont + A[i]
            #print (Acouont)
            if Acouont > x:
                break
            ans += 1
        print(ans)   
resolve()
# Judge status: Accepted
x, y, z = list(map(int, input().split()))
x, y = y, x
x, z = z, x

print(x,y,z)
# Judge status: Wrong Answer
a,b,c=map(int,input().split())
print(max(b//a,c))
# Judge status: Wrong Answer
n,a,b = map(int,input().split())

if a+b <= n:
	iter_num = n // (a+b)
	ans = iter_num * a

	ans += n - (a+b) * iter_num

	print(ans)
else:
	print(a)
# Judge status: Accepted
coin_500 = int(input())
coin_100 = int(input())
coin_50 = int(input())
total = int(input())
count = 0
# 合計金額の全通り
for i in range(coin_500 + 1):
    for j in range(coin_100 + 1):
        for k in range(coin_50 + 1):
            if 500 * i + 100 * j + 50 * k == total:
                count += 1

print(count)
# Judge status: Wrong Answer
s=input()
print(min([abs(753-int(s[i:i+3])) for i in range(len(s)-3)]))
# Judge status: Accepted
N = int(input())
B = list(map(int, input().split()))

A = [0] * N

for i in range(N):
    if i == 0:
        A[0] = B[0]
    elif i == N - 1:
        A[i] = B[i - 1]
    else:
        a = min(B[i - 1], B[i])
        A[i] = a

ans = sum(A)
print(ans)
# Judge status: Accepted
_,C=input(),input()
a=C.count('R')
print(a-C[:a].count('R'))
# Judge status: Wrong Answer
a, b = map(int, input().split());

if a * b <= 0 : 
  print('zero')
  exit(0)

if a > 0 and b > 0 :
  print('Positive')
  exit(0)

x = b - a + 1
if(x%2 == 0) : 
  print('Positive')
else :
  print('Negative')
# Judge status: Accepted
a,v = map(int, input().split())
b,w = map(int, input().split())
t = int(input())

if v <= w:
  print('NO')
else:
  if t*(v-w) >= abs(a-b):
    print("YES")
  else:
    print("NO")
# Judge status: Accepted
import fractions

A, B = map(int, input().split())

print(A * B // fractions.gcd(A, B))
# Judge status: Accepted
m,n=map(int,input().split())
res=m*n
if m==1 or n==1:
    print(1)
else:
  if res%2==0:
     print(res//2)
  else:
     print((res//2)+1)
# Judge status: Accepted
def solve():
    N, M = map(int, input().split())
    
    if N == 1 and M == 1:
        print(1)
        exit()
    
    if M < N:
        N, M = M, N
    if N == 1:
        print(M - 2)
        exit()
    
    print((N - 2) * (M - 2))


if __name__ == '__main__':
    solve()
# Judge status: Accepted
import math
R = int(input())
print(2*math.pi*R)
# Judge status: Wrong Answer
import math
a,b,x=map(int,input().split())
p=math.atan(2*x/a*b)
print(p)
# Judge status: Accepted
s  = input()
q  = int(input())
inv = 1
sfb = [0,"",""]
for i in range(q):
    ls = list(input().split())
    if ls[0] == "1":
        inv *=-1
    else:
        f,c = ls[1:]
        if f == "1":
            sfb[inv] +=c
        else:
            sfb[-inv] +=c

ans = sfb[1][::-1] + s + sfb[-1]
print(ans[::inv])
# Judge status: Accepted
from fractions import gcd
n = int(input())
aaa = list(map(int, input().split()))
p = aaa[0]
f = [p]
for a in aaa[1:-1]:
    p = gcd(p, a)
    f.append(p)
aaa.reverse()
p = aaa[0]
b = [p]
for a in aaa[1:-1]:
    p = gcd(p, a)
    b.append(p)
b.reverse()

f = [b[0]] + f
b = b + [f[-1]]

print(max(gcd(p, q) for p, q in zip(f, b)))
# Judge status: Accepted
A,B,C=map(int,input().split())
max=max(A,B,C)
sa=3*max-A-B-C
if sa%2!=0:
	max+=1
	sa=sa+3
print(sa//2)
# Judge status: Wrong Answer
# 169

# 入力を受け取ること

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

print(a)
print(b)

# 受け取った結果を使って計算する

answer = a * b

# 出力すること
print(answer)
# Judge status: Accepted
import sys
A,B = map(int,input().split())
if A < 0 or A > 13 or B < 0 or B > 13:
    sys.exit()

if A == 1 or B == 1:
    if A == B:
        print("Draw")
    elif A == 1:
        print("Alice")
    elif B == 1:
        print("Bob")
    sys.exit()

if A > B:
    print("Alice")
elif B > A:
    print("Bob")
else:
    print("Draw")
# Judge status: Accepted
x, y = map(int, input().split())
group = [[1,3,5,7,8,10,12], [4,6,9,11]]

if x == 2 or y == 2:
    print('No')
elif x in group[0]:
    if y in group[0]:
        print('Yes')
    else:
        print('No')
elif x in group[1]:
    if y in group[1]:
        print('Yes')
    else:
        print('No')
# Judge status: Accepted
import itertools
n=int(input())
p=list(map(int,input().split()))
q=list(map(int,input().split()))
a=[i for i in range(1,n+1)]
ans1=0
k=0
ans2=0
for i in itertools.permutations(a):
    if list(i)==p:
        ans1=k
    if list(i)==q:
        ans2=k
    k+=1
print(abs(ans1-ans2))
# Judge status: Accepted
#-*-coding:utf-8-*-
import sys
input=sys.stdin.readline

def ngram(data,n):
    return [data[i:i+n] for i in range(len(data))]

def main():
    s = input().rstrip()
    datas=ngram(s,3)
    answers=[]
    
    for data in datas:
        answers.append(abs(753-int(data)))
    print(min(answers))

if __name__=="__main__":
    main()
# Judge status: Accepted
a,b,c,x,y=map(int,input().split())
ans1=x*a+y*b
if x>=y:
    ans2=2*y*c+(x-y)*a#(x,y)=(3,2)であればABを4枚買う
else:
    ans2=2*x*c+(y-x)*b
ans3=2*max(x,y)*c
print(min(ans1,ans2,ans3))
# Judge status: Accepted
import sys
n, a, b = map(int, input().split())

# 2で割って余り1ならすれ違わない
if (b - a) % 2 == 0:
    print((b - a) // 2)

else:
    # 左で折り返す場合
    left = ((a - 1) + (b - 1) + 1) // 2

    # 右で折り返す場合
    right = ((n - b) + (n - a) + 1) // 2

    print(min(left, right))
# Judge status: Accepted
N=int(input())
A=list(map(int,input().split()))

ans=0
mx=0
for x in A:
    if mx>=x:
        ans+=mx-x
    else:
        mx=x

print(ans)
# Judge status: Accepted
N=int(input())
a=sorted(list(map(int,input().split())))

ans=10**9
for i in range(a[0],a[-1]+1):
  s=0
  for j in range(N):
    x=(a[j]-i)**2
    s+=x
  ans=min(ans,s)

print(ans)
# Judge status: Accepted
#abc120_a.py
A, B, C = map(int,input().split())
print(min(C,B//A))
# Judge status: Accepted
N, D = [int(x) for x in input().split()]

area = D * 2 + 1

result = -(-N // area)
print(result)
# Judge status: Accepted
N = input()
ans = 0

for i in range(len(N)):
    ans += int(N[i])

if ans >= 2:
    print(ans)
else:
    print(10)
# Judge status: Accepted
r = int(input())

ans = r*r
print(ans)
# Judge status: Wrong Answer
n, m = map(int, input().split())
ab = [list(map(int, input().split())) for _ in range(n)]
cd = [list(map(int, input().split())) for _ in range(m)]
print(ab)
print(cd)
for i in range(n):
    seq_min = 1e9
    ans = -1
    for j in range(m):
        seq = abs(ab[i][0] - cd[j][0]) + abs(ab[i][1] - cd[j][1])
        if seq_min > seq:
            seq_min = seq
            ans = j
    print(ans + 1)
# Judge status: Accepted
n = int(input())
flg=False

for i in range(0, 26):
    for j in range(0, 16):
        if(4*i+7*j==n):
            flg = True
            break
print("Yes" if flg else "No")
# Judge status: Wrong Answer
import fractions
from functools import reduce

n, x = map(int, input().split())
xx = [int(i) - x for i in input().split()]
xx.sort()

if n == 1:
    ans = xx[0]
else:
    dist = [xx[i + 1] - xx[i] for i in range(n - 1)]
    ans = reduce(fractions.gcd, dist)

print(ans)
# Judge status: Accepted
s = list(input())
if ('S' in s and 'N' not in s) or ('S' not in s and 'N' in s):
    print('No')
elif ('E' in s and 'W' not in s) or ('E' not in s and 'W' in s):
    print('No')
else:
    print('Yes')
# Judge status: Accepted
n=int(input())
a=[[0]*9 for i in range(9)]
for i in range(1,n+1):
    x,y =int(str(i)[0]), int(str(i)[-1])
    if y>0:
        a[x-1][y-1]+=1
count=0
for i in range(9):
    for j in range(9):
        if i>j:
            continue
        if i==j:
            count+=a[i][j]**2
        else:
            count+=a[i][j]*a[j][i]*2
print(count)
# Judge status: Accepted
import sys

sys.setrecursionlimit(10 ** 8)
ini = lambda: int(sys.stdin.readline())
inl = lambda: [int(x) for x in sys.stdin.readline().split()]
ins = lambda: sys.stdin.readline().rstrip()
debug = lambda *a, **kw: print("\033[33m", *a, "\033[0m", **dict(file=sys.stderr, **kw))


def solve():
    n = ini()
    s = ins()
    t = ins()
    for i in range(n + 1):
        if t.startswith(s[i:]):
            return len(s[:i] + t)

    return len(s + t)


print(solve())
# Judge status: Wrong Answer
num_str = input().split(" ")
S = input()

N = int(num_str[0])
K = int(num_str[1])
# Judge status: Wrong Answer
n, m = map(int, input().split())
a = list(map(int, input().split()))
a.sort()
for _ in range(m):
  p = a[n-1]//2
  up=n-1
  low=0
  while up-low == 1:
    nb = low+(up-low)//2
    if p <= a[nb]:
      up = nb
    else:
      low = nb
  a.insert(up, p)
print(sum(a[:n]))
# Judge status: Accepted
ans=""
s=input()
for i in s:
    if i=="0":
        ans+="0"
    elif i=="1":
        ans+="1"
    else:
        if i!=[]:
            ans=ans[:-1]
print(ans)
# Judge status: Wrong Answer
a,b,c=map(int,input().split());print(min(b,c)//a)
# Judge status: Wrong Answer
r=int(input())
l=r*3.14159265
print(l)
# Judge status: Accepted
s = input()
a = [s[0]]
tmp = ""
cnt = 1

for i in range(1, len(s)):
    tmp = tmp + s[i]
    if a[-1] != tmp:
        a.append(tmp)
        tmp = ""
        cnt += 1
    else:
        continue
print(cnt)
# Judge status: Wrong Answer
N=input()

if int(N[-1])==3:
	print("bon")
elif int(N[-1])==0 or 1 or 6 or 8:
	print("pon")
else:
	print("hon")
# Judge status: Accepted
S = input()
dir = [0]*4
move = "NWSE"
for i in S:
    dir[move.index(i)] += 1
p1 = (dir[0] > 0 and dir[2] > 0) or (dir[0] == 0 and dir[2] == 0)
p2 = (dir[1] > 0 and dir[3] > 0) or (dir[1] == 0 and dir[3] == 0)
print("Yes" if p1 and p2 else "No")
# Judge status: Accepted
a, b, c = map(int, input().split())

a1 = a//2
a2 = a - (a//2)
b1 = b//2
b2 = b - (b//2)
c1 = c//2
c2 = c - c//2

ans = min(a2*b*c - a1*b*c, b2 * a*c - b1*a*c)
ans = min(ans, c2 * a*b - c1 * a * b)
print(ans)
# Judge status: Accepted
n, x, t = map(int, input().split())

temp = int(n / x)
if n % x != 0:
    temp += 1

print(t * temp)
# Judge status: Accepted
n,k=map(int,input().split())
print(-((1-n)//(k-1)))
# Judge status: Wrong Answer
a,b = list(map(int,input().split()))

turu = 2
kame = 4
flag = 0

for x in range(a + 1):
    # print("xです{}".format(x))
    for y in range(a + 1):
        # print("yです{}".format(y))
        if kame * x + turu * y == b and (x + y) <= a:
            flag += 1
if flag == 0:
    print("No")
else:
    print("Yes")
# Judge status: Accepted
N = int(input())
s = input()
t = input()

if s == t:
    print(N)
else:
    for i in range(N):
        if s[i:] == t[:N - i]:
            print(N + i)
            break
    else:
        print(2 * N)
# Judge status: Accepted
N, x = list(map(int, input().split()))
A = list(map(int, input().split()))

#print(N, x)
A.sort()
#print(A)

cnt = 0
for a in A:
  if x >= a:
    x -= a
    cnt += 1
  
  else:
    break

if cnt == N and x > 0:
  cnt = cnt - 1
print(cnt)
# Judge status: Wrong Answer
n,t = input().split()
a,b = map(int,input().split())
print(a)
u = input()
if u == n:
    print(a-1,b)
else:
    print(a,b-1)
# Judge status: Accepted
import itertools

n=int(input())
a_list=list(map(int,input().split()))
sum=0
ps = list(itertools.accumulate(a_list))
for i in range(n-1):
  sum+=a_list[i]*(ps[n-1]-ps[i])

s=sum%(10**9+7)
print(s)
# Judge status: Wrong Answer
c = input()

if c == "a" or "e" or "i" or "o" or "u":
    print("vowel")
else:
    print("consonant")
# Judge status: Wrong Answer
N = int(input())
A_list = list(map(int,input().split()))

count=-1

for k in range(len(A_list)):
    for l in range(len(A_list)):
        if A_list[k] == A_list[l]:
            count+=1
    print(count)
    count=-1
# Judge status: Accepted
from math import ceil
N=int(input())
A=int(input())
B=int(input())
C=int(input())
D=int(input())
E=int(input())

def calc(A):
    if N%A==0:
        return N//A
    else:
        return N//A+1
a=calc(A)
b=1+max(a, calc(B))
c=2+max(b-1,calc(C))
d=3+max(c-2, calc(D))
e=4+max(d-3, calc(E))
print(e)
# Judge status: Wrong Answer
import numpy as np
import sys
input = sys.stdin.readline
n = int(input().rstrip())
s = 0
d = 0
e = min(n-2,3)
hanni = sorted([[int(x) for x in input().rstrip().split()] for _ in range(n)], key=lambda x: (x[1], x[0]))
for _ in range(n):
  if s != len(hanni)-1 and hanni[s][1] > hanni[s+1][0]:
    d += 1
    if d>=e:
      del hanni[s]
      d = 0
    else:
      s+=1
  else:
    s+=1
    d = 0
    
print(len(hanni))
# Judge status: Accepted

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

flag = 0
ans = 1
tmp = 0

for i in range(n):
    if i == 0:
        continue
    elif a_s[i] > a_s[i-1]:
        if flag == -1:
            ans += 1
            flag = 0
        else:
            flag = 1
    elif a_s[i] < a_s[i-1]:
        if flag == 1:
            ans += 1
            flag = 0
        else:
            flag = -1

print(ans)
# Judge status: Accepted
import collections

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

counter = collections.Counter(a_L)

ans = 0
for k,v in counter.items():
    if k == v:
        continue
    elif k < v:
        ans += v - k
    else:
        ans += v

print(ans)
# Judge status: Accepted
A, B, C, D = list(map(int, input().split(' ')))

turn = 0
while A > 0 and C > 0:
  if turn % 2 == 0:
    C -= B
  else:
    A -= D
  turn += 1

if A <= 0:
  print('No')
else:
  print('Yes')
# Judge status: Accepted
n , k = map(int,input().split())
ans = 0

def double(i,k):
    while i < k :
        i *= 2
    return i

for i in range(1,n+1):
    ans += (i / double(i,k)) / n
print(ans)
# Judge status: Accepted
s=str(input())
cnt=0
for i in range(len(s)):
    tmp=0
    for j in range(len(s)-i):
        
        if(s[i+j]=="A"or s[i+j]=="C"or s[i+j]=="G" or s[i+j]=="T"):
            tmp+=1
        else:
            break
    cnt = max(cnt,tmp)

print(cnt)