Harryxun/stf_run huggingface dataset:
N, Q = map(int, input().split())
S = input()
R = [list(map(int, input().split)) for i in range(Q)]
ans = []
for i in range(Q):
    x = R[i][0]-1
    y = R[i][1]
    a=S[x:y].count("AC")
    ans.append(a)

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

### FIXED CODE ###

N, Q = map(int, input().split())
S = input()
t = [0]*(N+1)
for i in range(N):
    t[i+1]=t[i] + (1 if S[i:i+2]=="AC" else 0)
for i in range(Q):
    l, r = map(int, input().split())
    print(t[r-1]-t[l-1])
N,K=int(input().split())
ans = 0
while (N > 0):
  N //= K
  ans += 1
print(ans)

### FIXED CODE ###

N,K=map(int, input().split())
ans = 0
while (N > 0):
  N //= K
  ans += 1
print(ans)
def resolve():
    import math
    a = [int(input()) for _ in range(5)]
    b = []
    for i in range(5):
        if a[i]%10 != 0:
            b.append(a[i]%10)
    if b == []
        amin = 0
    else:
        amin = min(b)
    ans = 0
    for i in range(5):
        ans += math.ceil(a[i]/10)*10
    print(ans-10+amin)

resolve()

### FIXED CODE ###

def resolve():
    import math
    a = [int(input()) for _ in range(5)]
    b = []
    for i in range(5):
        if a[i]%10 != 0:
            b.append(a[i]%10)
    if len(b) == 0:
        amin = 10
    else:
        amin = min(b)
    ans = 0
    for i in range(5):
        ans += math.ceil(a[i]/10)*10
    print(ans-10+amin)

resolve()
n, m = map(int, input().split())
a = list(map(int, input().split()))
a = sort(a)
b = sum(a)
c = 0
d = "Yes"
l = 1 / (4 * m)
b = b * l
while c < m:
  if a[c] < b:
    d = "No"
  c += 1
print(d)

### FIXED CODE ###

n, m = map(int, input().split())
a = list(map(int, input().split()))
a.sort(reverse = True)
b = 0
c = 0
d = ""
l = 1 / (4 * m)
for i in a:
    b += i
b = b * l
while c < m:
  if a[c] < b:
    d = "No"
  else:
    d = "Yes"
  c += 1
print(d)
import sys
sys.setrecursionlimit(10*7)

def dfs(G,v,color):
    #color[v] = True
    for next_v in G[v]:#next_v[0]=次の頂点、[1]=次までの距離
        if color[next_v[0]]==-1:
            color[next_v[0]] = (color[v] + next_v[1]) % 2 
            dfs(G,next_v[0],color)
        else:
            continue
    return color    

N = int(input())
G = [[] for _ in range(N)]
color = [-1] * N
color[0] = 0 #偶数=０

for i in range(N-1):
    a,b,c = map(int,input().split())
    a -= 1
    b -= 1
    G[a].append([b,c%2])
    G[b].append([a,c%2])

print(G)    
c = (dfs(G,0,color))
print(*c,sep="\n")


### FIXED CODE ###

import sys
sys.setrecursionlimit(10**9)

def dfs(now):
    for to,dis in G[now]:
        if color[to] == -1:
            color[to] = (color[now] + dis) % 2
            dfs(to)

N = int(input())
G = [[] for _ in range(N)]
color = [-1] * N
color[0] = 0 #偶数=0

for i in range(N-1):
    a,b,c = map(int,input().split())
    a -= 1
    b -= 1
    G[a].append([b,c%2])
    G[b].append([a,c%2])

#print(G)    
dfs(0)
print(*color,sep="\n")
n = int(input())
x = list(map(int, input().split()))
sorted_x = sorted(x)

if sorted_x[n // 2] == sorted_x[n // 2 - 1]:
    print(' '.join([sorted_x[n // 2] * n]))
else:
    ret = []
    for i in range(n):
        if x[i] >= sorted_x[n // 2]:
            ret.append(sorted_x[n // 2])
        else:
            ret.append(sorted_x[n // 2 - 1])
    print(' '.join(ret))


### FIXED CODE ###

n = int(input())
x = list(map(int, input().split()))
sorted_x = sorted(x)

if sorted_x[n // 2] == sorted_x[n // 2 - 1]:
    ret = [sorted_x[n // 2]] * n
else:
    ret = []
    for i in range(n):
        if x[i] >= sorted_x[n // 2]:
            ret.append(sorted_x[n // 2 - 1])
        else:
            ret.append(sorted_x[n // 2])
for i in ret:
    print(i)
from collections import Counter

def mapdict(n, dictionary):
    return dict(map(lambda t:(t[0]-n,t[1]), dictionary.items()))

def count(dic):
    count = 0
    for k,v in dic.items():
        count += abs(k*v)
    return count

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

A2 = sorted([A[i-1]-i for i in range(1,N+1)])


Adic = Counter(A2)
Ax  = A2[N//2]
Adic = mapdict(Ax, Adic)

res = count(Adic)
pl = count(mapdict(A2[N//2 +1],Adic))
mn = count(mapdict(A2[N//2 -1],Adic))


if pl<=res:
    tmp = pl
    tmpc = 1
    while tmp <= res:
        tmpc += 1
        if N//2 + tmpc > N-1:
            break
        res = tmp
        Adic = mapdict(A2[N//2 +tmpc], Adic)
        tmp = count(Adic)
        

elif mn<=res:
    tmp = mn
    tmpc = 1
    while tmp <= res:
        tmpc += 1
        if N//2 - tmpc < 0:
            break
        res = tmp
        Adic = mapdict(A2[N//2 -tmpc], Adic)
        tmp = count(Adic)

print(res)

### FIXED CODE ###

from collections import Counter

def mapdict(n, dictionary):
    return dict(map(lambda t:(t[0]-n,t[1]), dictionary.items()))

def count(dic):
    count = 0
    for k,v in dic.items():
        count += abs(k*v)
    return count

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

A2 = sorted([A[i-1]-i for i in range(1,N+1)])


Adic = Counter(A2)
Ax  = A2[N//2]
Adic = mapdict(Ax, Adic)

res = count(Adic)

if N==1:
    print(0)

elif N==2:
    print(sum(map(abs,map(lambda x:x-min(A2),A2))))

else:
    pl = count(mapdict(A2[N//2 +1],Adic))
    mn = count(mapdict(A2[N//2 -1],Adic))
    if pl<=res:
        tmp = pl
        tmpc = 1
        while tmp <= res:
            tmpc += 1
            if N//2 + tmpc > N-1:
                break
            res = tmp
            Adic = mapdict(A2[N//2 +tmpc], Adic)
            tmp = count(Adic)
    elif mn<=res:
        tmp = mn
        tmpc = 1
        while tmp <= res:
            tmpc += 1
            if N//2 - tmpc < 0:
                break
            res = tmp
            Adic = mapdict(A2[N//2 -tmpc], Adic)
            tmp = count(Adic)

    print(res)
a = int(input())
b = int(input())
if a+b == 3:
    print(3)
elif a+b ==5
    print(1)
else:
    print(2)

### FIXED CODE ###

a = int(input())
b = int(input())
if a+b == 3:
    print(3)
elif a+b == 5:
    print(1)
else:
    print(2)
x = int(input())
if 400 <= x < 600:
    print(8)
elif 600 <= x < 800:
    print(7)
elif 800 <= x < 1000:
    print(6)
elif 1000 <= x < 1200:
    print(5)
elif 1200 <= x < 1400:
    print(4)
elif 1400 <= x < 1600:
    print(3)
elif 1600 <= x < 1800:
    print(2)
elif 1800 <= x < 2000:
    print(1)
x = int(input())
if 400 <= x < 600:
    prtint(8)
elif 600 <= x < 800:
    print(7)
elif 800 <= x < 1000:
    print(6)
elif 1000 <= x < 1200:
    print(5)
elif 1200 <= x < 1400:
    print(4)
elif 1400 <= x < 1600:
    print(3)
elif 1600 <= x < 1800:
    print(2)
elif 1800 <= x < 2000:
    print(1)

### FIXED CODE ###

import sys
import  math
import fractions
from collections import defaultdict
stdin = sys.stdin
     
ns = lambda: stdin.readline().rstrip()
ni = lambda: int(stdin.readline().rstrip())
nm = lambda: map(int, stdin.readline().split())
nl = lambda: list(map(int, stdin.readline().split()))
 
X=int(input())
ans=0
if(400<=X and X<=599):
    ans=8
if(600<=X and X<=799):
    ans=7
if(800<=X and X<=999):
    ans=6
if(1000<=X and X<=1199):
    ans=5
if(1200<=X and X<=1399):
    ans=4
if(1400<=X and X<=1599):
    ans=3
if(1600<=X and X<=1799):
    ans=2
if(1800<=X and X<=1999):
    ans=1
 
print(ans)
def find_word(sent, word):
    w = word    
    if sent.find(w) > -1:
        return w,y
    elif len(w) == 0:
        return w,"No"
    else:
        return find_word(sent,w[:-1])


sent = raw_input()
word = raw_input()
s = ""
s,y = find_word(sent,word)

b = word.replace(s,"")

a,y= find_word(sent,b)
print y

### FIXED CODE ###

s = raw_input()
p = raw_input()

s += s

if p in s:
    print "Yes"
else:
    print "No"
N = int(input())
def count(start, end):
  return end - start + 1
keta = 1
while True:
  if 10**keta > N:
    break
  else:
    keta += 1  
num = 0
for k in range(1, keta+1):
  if k % 2 == 1:
    num += count(10**(k-1), min(N, 10**k-1))
print(num)

### FIXED CODE ###

A, B, C = list(map(int, input().split()))
 
ABgap = A - B
remain = max(0, C - ABgap)
 
print(remain)
c = input()
vowel = [a, i, u, e, o]
print("vowel" if c in vowel else "consonant")

### FIXED CODE ###

c = input()
vowel = ["a", "i", "u", "e", "o"]
print("vowel" if c in vowel else "consonant")
import numpy as np
n = int(input())
a = np.array(list(map(int, input().split())))

if 0 in a:
  b = list(map(abs, a))
  print(sum(b))
  
else:
  if (a[a<0].size % 2) == 0:
    b = list(map(abs, a))
    print(sum(b))
  else:
    b = list(map(abs, a))
    c = sorted(b).reverse()
    d = c.pop()
    print(sum(c))

    

### FIXED CODE ###

import numpy as np
n = int(input())
a = np.array(list(map(int, input().split())))

if 0 in a:
  b = list(map(abs, a))
  print(sum(b))
  
else:
  if (a[a<0].size % 2) == 0:
    b = list(map(abs, a))
    print(sum(b))
  else:
    b = list(map(abs, a))
    b = sorted(b)
    b.reverse()
    c = b.pop()
    print(sum(b)-c)
x, y = map(int, input().split())

ans = 0
diff = y-x
abs_diff = abs(abs(y)-abs(x))

ans += abs_diff

if abs_diff == diff:
    ans += 0

elif diff == -1*(abs_diff):
    ans += 2
    if x == 0 or y == 0:
        ans -= 1
else:
    ans += 1

print(ans)
x, y = map(int, input().split())

ans = 0
diff = y-x
abs_diff = abs(abs(y)-abs(x))

ans += abs_diff

if abs_diff == diff:
    ans += 0

elif diff == -1*(abs_diff):
    ans += 2
    if x == 0 or y == 0:
        ans -= 1
else:
    ans += 1

print(ans)


### FIXED CODE ###

x, y = map(int, input().split())

ans = 0
diff = y-x
abs_diff = abs(abs(y)-abs(x))

ans += abs_diff

if abs_diff == diff:
    ans += 0

elif diff == -1*(abs_diff):
    ans += 2
    if x == 0 or y == 0:
        ans -= 1
else:
    ans += 1

print(ans)
o = list(input())
e = list(input())

for i in range(len(o)):
  print(o[i],e[i],end="")

### FIXED CODE ###

o = list(input())
e = list(input())+[""]
for x,y in zip(o,e):
  print(x+y,end="")
n = int(input())
d = list(map(int,input().split()))
d = sorted(d)
l = d[n/2-1]
r = d[n/2]
print(r-l)


### FIXED CODE ###

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

diff = sorted(diff)
l = diff[int(n/2)-1]
r = diff[int(n/2)]
print(r-l)
from collections import Counter

n = int(input())
s = mapt(int, input().split(" "))
data = Counter(s)
for i in range(1, n+1):
    print(data.get(i, 0))

### FIXED CODE ###

from collections import Counter

n = int(input())
s = map(int, input().split(" "))
data = Counter(s)
for i in range(1, n+1):
    print(data.get(i, 0))
def combinations_count(n, r):
  return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))
if A == 0:
  D = combinations_count(B, 2)
  print(D)
  exit()
elif B == 0:
  C = combinations_count(A, 2)
  exit()
C = combinations_count(A, 2)
D = combinations_count(B, 2)
print(C+D)

### FIXED CODE ###

A,B = list(map(int,input().split()))
import math
if A == 0 and B != 0:
  D = math.factorial(B-2)
  F = math.factorial(B) // 2// D
  print(F)
  exit()
if A != 0 and B == 0:
  C = math.factorial(A-2)
  E = math.factorial(A) // 2// C
  print(E)
  exit()
if A == 0 and B == 0:
  print(0)
  exit()
elif A == 1 and B != 1:
  D = math.factorial(B-2)
  F = math.factorial(B) // 2// D
  print(F)
  exit()
elif A != 1 and B == 1:
  C = math.factorial(A-2)
  E = math.factorial(A) // 2// C
  print(E)
  exit()
elif A == 1 and B == 1:
  print(0)
  exit()
C = math.factorial(A-2)
D = math.factorial(B-2)
E = math.factorial(A) // 2// C
F = math.factorial(B) // 2// D
print(E+F)
n, c = map(int, input().split())
X = []
V = []
right = []
rightleft = []
calsum = 0
for i in range(n):
    x, v = map(int, input().split())
    X.append(x)
    V.append(v)
    calsum += v
    right.append(calsum-x)
    rightleft.append(calsum-2*x)

left = []
leftright = []
calsum = 0
results = []
for i in range(n):
    calsum += V[n-i-1]
    left.append(calsum - (c-X[n-i-1]))
    leftright.append(calsum - 2*(c-X[n-i-1]))

rl = []
for i, v in enumerate(rightleft):
    l = list(map(lambda x: x+v, left[:n-i-1]))
    if len(l) > 0:
        rl.append(max(l))

lr = []
for i, v in enumerate(leftright):
    l = list(map(lambda x: x+v, right[:n-i-1]))
    if len(l) > 0:
        lr.append(max(l))

print(max(*right, *left, *rl, *lr, 0))


### FIXED CODE ###

n, c = map(int, input().split())
X = []
V = []
right = []
rightleft = []
calsum = 0
for i in range(n):
    x, v = map(int, input().split())
    X.append(x)
    V.append(v)
    calsum += v
    right.append(calsum-x)
    rightleft.append(calsum-2*x)

left = []
leftright = []
calsum = 0
for i in range(n):
    calsum += V[n-i-1]
    left.append(calsum - (c-X[n-i-1]))
    leftright.append(calsum - 2*(c-X[n-i-1]))

m = 0
M = 0
for i in range(0, n-1):
    m = max(m, left[i])
    M = max(M, m + rightleft[n-i-2])

mm = 0
MM = 0
for i in range(0, n-1):
    mm = max(mm, right[i])
    MM = max(MM, mm + leftright[n-i-2])

print(max(max(right), max(left), M, MM, 0))
N,A,B,K = map(int,input().split()
sprime = 998244353 # approx 10**9
A,B = sorted((A,B))
if (A+B) * N < K:
	print(0)
	exit()

def egcd(a, b):
    if a == 0:
        return (b, 0, 1)
    else:
        g, y, x = egcd(b % a, a)
        return (g, x - (b // a) * y, y)

def modinv(a, m):
    g, x, y = egcd(a, m)
    if g != 1:
        raise Exception('modular inverse does not exist')
    else:
        return x % m

memo = [0] * (N+1)
memo[0] = memo[N] = 1
for i in range(1,N//2+1):
	v = memo[i-1] * (N-i+1) * modinv(i,sprime)
	v = v % sprime
	memo[i] = memo[N-i] = v

# max is A*N + B*N
sum = 0
for j in range(0,N):
	i = (K-B*j)//A
	if 0 <= i <= N and A*i+B*j==K:
		sum += memo[i] * memo[j]
		sum %= sprime

print(sum)



### FIXED CODE ###

N,A,B,K = map(int,input().split())
sprime = 998244353 # approx 10**9
A,B = sorted((A,B))
if (A+B) * N < K:
	print(0)
	exit()
 
def egcd(a, b):
    if a == 0:
        return (b, 0, 1)
    else:
        g, y, x = egcd(b % a, a)
        return (g, x - (b // a) * y, y)
 
def modinv(a, m):
    g, x, y = egcd(a, m)
    if g != 1:
        raise Exception('modular inverse does not exist')
    else:
        return x % m
 
memo = [0] * (N+1)
memo[0] = memo[N] = 1
for i in range(1,N//2+1):
	v = memo[i-1] * (N-i+1) * modinv(i,sprime)
	v = v % sprime
	memo[i] = memo[N-i] = v
 
# max is A*N + B*N
sum = 0
for b in range(N+1):
  a = (K-b*B)//A
  if 0 <= a <= N and a*A+b*B == K:
    sum += memo[a]*memo[b]
    sum %= sprime

print(sum)
lis = []
for _ in range(5):
  lis.append(int(input()))
mod = []
for i in lis:
  mod.append(i%10)
k = min(mod) if min(mod) != 0 else sorted(set(mod))[1]
ans = 0
for i in range(5):
  if i == mod.index(k):
    ans += lis[i]
  else:
    ans += ((lis[i]+9)//10)*10
print(ans)
    

### FIXED CODE ###

lis = []
for _ in range(5):
  lis.append(int(input()))
mod = []
for i in lis:
  mod.append(i%10)
if mod == [0,0,0,0,0]:
  print(sum(lis))
else:
  k = min(mod) if min(mod) != 0 else sorted(set(mod))[1]
  ans = 0
  for i in range(5):
    if i == mod.index(k):
      ans += lis[i]
    else:
      ans += ((lis[i]+9)//10)*10
  print(ans)
# TLE
N = int(input())
a = list(map(int, input().split()))

cnt = [0] * 100000
for i in a:
    cnt[i] += 1
    cnt[i+1] += 1
    cnt[i-1] += 1

print(max(cnt))

### FIXED CODE ###

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

cnt = [0] * 1000010
for i in a:
    cnt[i] += 1
    cnt[i+1] += 1
    cnt[i-1] += 1

print(max(cnt))
N,M = (int(x) for x in input().split())

K = N/M
if N < M:
  print(1)
else if N > M && N%M == 0:
  print(K)
else:
  print(K+1)



### FIXED CODE ###

N,M = (int(x) for x in input().split())
 
K = int(N/M)
if N < M:
  print(1)
elif N%M == 0:
  print(K)
else:
  print(K+1)
n, m, k = map(int, input().split())
a = list(map(int, input().split()))
b = list(map(int, input().split()))

def dfs(ai, bi, t, c):
    if t > k:
        return c - 1
    elif ai == n - 1 and bi == m - 1:
        return c
    elif ai == n - 1:
        return dfs(ai, bi + 1, t + b[bi], c + 1)
    elif bi == m - 1:
        return dfs(ai + 1, bi, t + a[ai], c + 1)
    return max(dfs(ai + 1, bi, t + a[ai], c + 1), dfs(ai, bi + 1, t + b[bi], c + 1))

ans = dfs(0, 0, 0, 0)

print(ans)


### FIXED CODE ###

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

A = [0] * (n + 1)
for i in range(1, n + 1):
    A[i] = A[i - 1] + a[i - 1]

B = [0] * (m + 1)
for i in range(1, m + 1):
    B[i] = B[i - 1] + b[i - 1]

ans = 0
best = m
for i in range(n + 1):
    for j in range(best, -1, -1):
        t = A[i] + B[j]
        if t <= k:
            ans = max(ans, i + j)
            best = j
            break
print(ans)
import sys
input = sys.stdin.readline
import math
from functools import reduce

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

d = [abs(X-x[i]) for i in range(N)]

def gcd(numbers):
    return reduce(math.gcd, numbers)

print(gcd(d))

### FIXED CODE ###

import sys
input = sys.stdin.readline
import math

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

d = [abs(X-x[i]) for i in range(N)]
oppai = d[0]

def gcd(a, b):
	while b:
		a, b = b, a % b
	return a


for i in range(N-1):
    oppai = gcd(oppai,d[i+1])

print(oppai)
w, h, x, y = map(int, input().split())
print((x * y) / 2, 1 if [x, y]=[w / 2, h / 2] else 0)

### FIXED CODE ###

w, h, x, y = map(int, input().split())
print((w * h) / 2, 1 if [x * 2, y * 2] == [w, h] else 0)
N=int(input())

A=''
for i in range(3):
  if N[i]==1:
    A=A+'9'
  else:
    A=A+'1'

print(int(A))

### FIXED CODE ###

N=str(input())

A=''
for i in range(3):
  if N[i]=='9':
    A=A+'1'
  else:
    A=A+'9'

print(int(A))
x_1,y_1,x_2,y_2 = list(map(int,input().split()))

A = x_2 - x_1 
B = y_2 - y_1

print(x_2-B,y_2+A,x_1-B,y_1+A)

### FIXED CODE ###

N = int(input())
print(int((N/2)**2))
n = 10**5
primes = set(range(2, n+1))
for i in range(2, int(n**0.5+1)):
    primes.difference_update(range(i*2, n+1, i))
primes=list(primes)

m = int(input())
for i in range(len(primes)):
  if primes[i] < m and m < primes[i+1]:
    print(primes[i+1])
    


### FIXED CODE ###

m = int(input())
if m <= 2 :
  print('2')
else:
  n = 10**6
  primes = set(range(2, n+1))
  for i in range(2, int(n**0.5+1)):
      primes.difference_update(range(i*2, n+1, i))
  primes=list(primes)

  for i in range(len(primes)-1):
    if primes[i] < m and m <= primes[i+1]:
      print(primes[i+1])
#!/mnt/c/Users/moiki/bash/env/bin/python
N,P = list(map(int, input().split()))
import math


def get_prime(n):
    """ Returns  a list of primes < n """
    sieve = [True] * n
    for i in range(3,int(n**0.5)+1,2):
        if sieve[i]:
            sieve[i*i::2*i]=[False]*((n-i*i-1)//(2*i)+1)
    return [2] + [i for i in range(3,n,2) if sieve[i]]

primax = int(1e7) + 9 * int(1e6)
primes = get_prime(primax)




def df(P, p):
    if P >= p:
        cnt = 0
        while P >= p and P % p == 0:
            P = int(P//p)
            cnt += 1
        return cnt
    else:
        raise "P , p error."

gc = []
for p in primes:
    if P % p == 0:
        cnt = df(P, p)
        P = int( P // int(p**cnt))
        gc.append([p, cnt])
ans = 1
for g,cnt in gc:
    if cnt >= N:
        ans *= g**(cnt//N)

debug = 1
for g,cnt in gc:
    debug *= g**cnt

# N > 100:  why WA
# debug < P: under 3 RE

if P > 1e9 and debug != P and  debug < (P//2):
    raise "errror"
print(ans)


### FIXED CODE ###

#!/mnt/c/Users/moiki/bash/env/bin/python
N,P = list(map(int, input().split()))
import math

if N == 1:
    print(P)
    exit(0)

def get_prime(n):
    """ Returns  a list of primes < n """
    sieve = [True] * n
    for i in range(3,int(n**0.5)+1,2):
        if sieve[i]:
            sieve[i*i::2*i]=[False]*((n-i*i-1)//(2*i)+1)
    return [2] + [i for i in range(3,n,2) if sieve[i]]

primax = int(1e7) + 9 * int(1e6)
primes = get_prime(primax)
# print(primes)



def df(P, p):
    if P >= p:
        cnt = 0
        while P >= p and P % p == 0:
            P = int(P//p)
            cnt += 1
        return cnt
    else:
        raise "P , p error."

gc = []
for p in primes:
    if P % p == 0:
        cnt = df(P, p)
        P = int( P // int(p**cnt))
        gc.append([p, cnt])
ans = 1
for g,cnt in gc:
    if cnt >= N:
        ans *= g**(cnt//N)

debug = 1
for g,cnt in gc:
    debug *= g**cnt

# N > 100:  why WA
# debug < P: under 3 RE
# debug*2 > P:  None
if P > 1e9 and debug != P and  debug < P and N == 1:
    raise "errror"
print(ans)
n = int(input())
print(n**)


### FIXED CODE ###

n = int(input())
print(n**3)
a,b,c = list(map(int, input().split()))
d,e,f = list(map(int, input().split()))	
g,h,k = list(map(int, input().split()))
N = int(input())
l = []
for i in range(N):
	e=int(input())
	l.append(e)
L1 = {a,d,g}
L2 = {a,b,c}
L3 = {a,e,k}
L4 = {c,f,k}
L5 = {g,h,k}
L6=  {c,e,g}
for i in range(N):
	for j in range(N):
		for k in range(N):
			s = set([l[i],l[j],l[k]])
			if (s == L1) or (s == L2) or (s == L3) or (s == L4) or (s == L5) or (s==L6):
				print('Yes')
				exit(0)
		
print('No')











### FIXED CODE ###

N = int(input())
if N%2 == 0:
  print(N//2)
else:
  print(N//2 + 1)
Z=[]
Q=[]
Y=[]
for i in range(5):
    a=int(input())
    Q.append(a)
    if a% 10!=0:
        Z.append(10-a % 10+a)
        Y.append(a % 10)
    else:
        Z.append(a)

print(sum(Z)-(10-min(Y)))

### FIXED CODE ###

Z=[]
Y=[]
for i in range(5):
    a=int(input())
    if a% 10!=0:
        Z.append(10-a % 10+a)
        Y.append(a % 10)
    else:
        Z.append(a)
if len(Y)==0:
    H=10
else:
    H=min(Y)

print(sum(Z)-(10-H))
#!/usr/bin/env python3
import sys
import bisect


def solve(H: int, W: int, S: "List[str]"):
    L = [[0 for _ in range(W)] for _ in range (H)]
    R = [[0 for _ in range(W)] for _ in range (H)]
    D = [[0 for _ in range(W)] for _ in range (H)]
    U = [[0 for _ in range(W)] for _ in range (H)]

    for i in range(H):
        for j in range(W):
            if S[i][j] == "#":
                L[i][j] = 0
            elif j > 0:
                L[i][j] = L[i][j-1] + 1
            else:
                L[i][j] = 1

        for j in range(W-1,-1,-1):
            if S[i][j] == "#":
                R[i][j] = 0
            elif j < W-1:
                R[i][j] = R[i][j+1] + 1
            else:
                R[i][j] = 1

    for j in range(W):
        for i in range(H):
            if S[i][j] == "#":
                U[i][j] = 0
            elif i > 0:
                U[i][j] = U[i-1][j] + 1
            else:
                U[i][j] = 1

        for i in range(H-1,-1,-1):
            if S[i][j] == "#":
                D[i][j] = 0
            elif i < H-1:
                D[i][j] = D[i+1][j] + 1
            else:
                D[i][j] = 1

    res = 0
    for i in range(H):
        for j in range(W):
            res = max(res, L[i][j] + R[i][j] +U[i][j] +D[i][j] -3)

    print(res)





# Generated by 1.1.4 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    H = int(next(tokens))  # type: int
    W = int(next(tokens))  # type: int
    S = [ next(tokens) for _ in range(H) ]  # type: "List[str]"
    solve(H, W, S)

if __name__ == '__main__':
    main()


### FIXED CODE ###

#!/usr/bin/env python3
import sys


def solve(P: int, Q: int, R: int):
    print(min(P+Q,P+R,Q+R))
    return


# Generated by 1.1.4 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    P = int(next(tokens))  # type: int
    Q = int(next(tokens))  # type: int
    R = int(next(tokens))  # type: int
    solve(P, Q, R)

if __name__ == '__main__':
    main()