Harryxun/stf_run huggingface dataset:
n, k=map(int, input().split())

ans=k*(k-1)**(n-1)

print(ans)

### FIXED CODE ###


def penki(a, b, c):
  if a==b and b==c:
    return 1
  elif a!=b and b!=c and c!=a:
    return 3
  else:
    return 2

a,b,c=map(int, input().split())
print(penki(a, b, c))
# -*- coding:utf-8 -*-
import sys
N = int(input())
s = sorted([ int(input()) for tmp in range(N) ])
total = sum(s)
if total%10 != 0:
    print(total)
else:
    for tmp in s:
        total -= tmp
        if total%10 != 0:
            print(total)
            sys.exit()
        else:
            pass
    print(0)

### FIXED CODE ###

# -*- coding:utf-8 -*-
a = sum(list(map(int,input().split())))
if a >= 10:
    print("error")
else:
    print(a)
import math

r = int(input())

area = math.pi * r * r
circle = 2 * math.pi * r

print("{:.8f} {:.8f}".format(area, circle))



### FIXED CODE ###

import math

r = float(input())

area = math.pi * r * r
circle = 2 * math.pi * r

print("{:.8f} {:.8f}".format(area, circle))
s = raw_input().split()
[N, K] = s
N = int(N)
K = int(K)
#print N, K

s = raw_input().split()
#print s
h = [0]*N

for i in range(N):
    h[i] = int(s[i])
    #print h[i]

h.sort(reverse=True)
#print h

for i in range(N):
    if (h[i] >= K):
        continue
    else:
        print i
        exit()

print N


### FIXED CODE ###

v=int(input())
if (v % 2 == 0):
    print 0.5
else:
    print (v/2+1.0)/v
H,W = map(int, input().split())
A = []
for _ in range(H):
    A += [ [ x == "#" for x in input()] ]

import numpy as np
from scipy import ndimage
A = np.array(A, dtype= np.bool)
B = np.zeros(A.shape, dtype=np.bool)
i = 0
S = H * W
struct = ndimage.generate_binary_structure(2, 1)
while True:
    if np.alltrue(A):
        break
    ndimage.binary_dilation(A, structure=struct, output=B)
    A, B = B, A

    i += 1

print(i)

### FIXED CODE ###

from collections import deque
H,W = map(int, input().split())
A = 0
dp = [None] * H
mat = [None] * (H*W)
matS = matE = 0
for h in range(H):
    s = list(input())
    for w, x in zip(range(W), s):
        if x == "#":
            mat[matE] = (h, w, 0)
            matE+=1
    dp[h] = s

def search(dp, mat, nH, nW, cnt):
    global matE
    if dp[nH][nW] == ".":
        mat[matE] = (nH, nW, cnt+1)
        matE+=1
        dp[nH][nW] = "#"

while matS < matE:
    h, w, cnt = mat[matS]
    matS += 1

    if h > 0:
        search(dp, mat, h - 1, w, cnt)
    if h < H-1:
        search(dp, mat, h + 1, w, cnt)
    if w > 0:
        search(dp, mat, h , w - 1, cnt)
    if w < W-1:
        search(dp, mat, h , w + 1, cnt)

print(cnt)
ai = lambda: list(map(int,input().split()))

mod = 10**9+7


def nCb(n, b):
    if b > n - b:
        b = n - b
    r = 1
    for k in range(n, n-b, -1):
        r = r * k % mod
    d = 1
    for k in range(1, b+1):
        d = d * k % mod
    return r * inv(d) % mod


def inv(x):
    return pow(x, mod - 2, mod)


h,w,a,b = ai()
aa = h-a-1
bb = w-b-1
c1 = nCb(aa+b, b)
c2 = nCb(a+bb-1, bb)
ans = c1 * c2
ans %= mod

for i in range(1, bb+1):
    c1 = c1 * (aa + b + i) * inv(b + i) % mod
    c2 = c2 * (bb - i + 1) * inv(a + bb - i) % mod
    ans += c1 * c2
    ans %= mod
print(ans)


### FIXED CODE ###

N,k = list(map(int,input().split()))
d = list(map(int, input().split()))

while True:
    m = list(str(N))
    f = 0
    for i in d:
        if str(i) in m:
            f += 1
    if f == 0:
        print(N)
        break
    N += 1
N = int(input())
A = list(map(int, input().split()))

answer = N
for i in range(N-1):
    v = A[i]
    for j in range(i+1, N):
        vx = v ^ A[j]
        vp = v + A[j]
        if vx == vp:
            answer += 1
            v = vx
        else:
            break
print(answer)


### FIXED CODE ###

N = int(input())
S = input()

from collections import defaultdict
wc = defaultdict(int)
ec = defaultdict(int)

if S[0] == 'W':
    wc[0] = 1
for i in range(1, N):
    wc[i] = wc[i-1]
    if S[i] == 'W':
        wc[i] += 1

if S[N-1] == 'E':
    ec[N-1] = 1
for i in range(N-2, -1, -1):
    ec[i] = ec[i+1]
    if S[i] == 'E':
        ec[i] += 1

min_ = N
for i in range(1, N-1):
    v = wc[i-1] + ec[i+1]
    if v < min_:
        min_ = v
v0 = ec[1]
if v0 < min_:
    min_ = v0
vn = wc[N-1]
if vn < min_:
    min_ = vn
print(min_)
N=int(input())
P=list(map(int,input().split()))

total=1
minP=P[0]
for i in range(1,N):
    if P[i]<minP:
        total+=1
        minP=P[i]
print(total)


### FIXED CODE ###

N,M=input().split()
if N==M:
  print("Yes")
else:
  print("No")
s=input()

print(n**3)


### FIXED CODE ###

n=int(input())

print(n**3)
n, *a = map(int, input().split())
cnt = 0
li = []


def hantei(s):
    for i in range(n-1):
        if s[i] > s[i+1]:
            return False
    return True
    

for i in range(n-1):
    if a[i] > a[i+1]:
        li.append(i+1)


if len(li) < 2:
    print('YES')

elif len(li) >= 2:
    a[li[0]], a[li[1]] = a[li[1]], a[li[0]]
    if hantei(a):
        print('YES')
    else:
        print('NO')

### FIXED CODE ###

from collections import defaultdict, deque
from heapq import heappush, heappop, heapify
import math
import bisect
import random
from itertools import permutations, accumulate
import sys


def LI(): return list(map(int, sys.stdin.readline().split()))
def I(): return int(sys.stdin.readline())
def LIM(): return list(map(lambda x:int(x) - 1, sys.stdin.readline().split()))
def LS(): return sys.stdin.readline().split()
def S(): return sys.stdin.readline()
def IR(n): return [I() for i in range(n)]
def LIR(n): return [LI() for i in range(n)]
def LIRM(n): return [LIM() for i in range(n)]
def SR(n): return [S() for i in range(n)]
def LSR(n): return [LS() for i in range(n)]
def SRL(n): return [list(S()) for i in range(n)]
mod = 1000000007


def main():
    n = I()
    num = LI()
    for i in range(n):
        for j in range(n):
            tmp = num.copy()
            tmp[i], tmp[j] = tmp[j], tmp[i]
            if tmp == sorted(num):
                return 'YES'
    return 'NO'


print(main())
N = int(input())
S = [int(input()) for _ in range(N)]
table = [False] * (100 * 100 + 1)
table[0] = True
ma = 0
for s in S:
    ma += s
    for i in range(ma, -1, -1):
        table[i+s] |= table[i]
for i in range(ma, -1, -1):
    if i % 10 != 0 and table[i]:
        print(i)
        break
else:
    print(0)



### FIXED CODE ###

N = int(input())
S = [int(input()) for _ in range(N)]
table = [False] * (200 * 200 + 1)
table[0] = True
ma = 0
for s in S:
    ma += s
    for i in range(ma, -1, -1):
        table[i+s] |= table[i]
for i in range(ma, -1, -1):
    if i % 10 != 0 and table[i]:
        print(i)
        break
else:
    print(0)
a,b,c,d,e,k=map(int,input().split())
if e-a>k:
  print(":(")
else:
  print('Yay!')

### FIXED CODE ###

a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
if e-a>k:
  print(":(")
else:
  print('Yay!')
S = input()
T = input()
replaces = 0
for ch in range(S):
  if S[ch] == T[ch]:
    replaces += 1

print(replaces)

### FIXED CODE ###

S = input()
T = input()
replaces = 0
for ch in range(len(S)):
    if S[ch] != T[ch]:
        replaces += 1

print(replaces)
n, x = map(int, input().split())

burger = [1]*(n+1)
patty = [1]*(n+1)

stopped = 0
for i in range(1,n):
	burger[i] = 2*burger[i-1]+3
	patty[i] = 2*patty[i-1]+1
	
def solve(n, x):
	if n = 0:
		if x = 0:
			return 0
		else:
			return 1
	elif x == 0:
		return 0
	elif x == burger[n]:
		return patty[n]
	elif x == burger[n-1]+1:
		return patty[n-1]
	elif x == burger[n-1]+2:
		return patty[n-1]+1
	elif x < burger[n-1]+2:
		return solve(n-1, x-1)
	elif x > burger[n-1]+2:
		return solve(n-1, x-burger[n-1]-2)+patty[n-1]+1

print(solve(n, x))

### FIXED CODE ###

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

burger = [1]*(n+1)
patty = [1]*(n+1)

stopped = 0
for i in range(1,n):
	burger[i] = 2*burger[i-1]+3
	patty[i] = 2*patty[i-1]+1
	
def solve(n, x):
	if n == 0:
		if x == 0:
			return 0
		else:
			return 1
	elif n == 1:
		if x == 0:
			return 0
		elif x == 1:
			return 0
		elif x == 2:
			return 1
		elif x == 3:
			return 2
		elif x == 4:
			return 3
		else:
			return 3
	elif x == 0:
		return 0
	elif x == burger[n]:
		return patty[n]
	elif x == burger[n-1]+1:
		return patty[n-1]
	elif x == burger[n-1]+2:
		return patty[n-1]+1
	elif x < burger[n-1]+2:
		return solve(n-1, x-1)
	elif x > burger[n-1]+2:
		return solve(n-1, x-burger[n-1]-2)+patty[n-1]+1

print(solve(n, x))
s1 = input()
t1 = input()

s = list(s1)
t = list(t1)

s.sort()
t.sort(reverse=1)

i = 0
while(1):
  if ord(s[i]) < ord(t[i]):
    print('YES')
    break
  else :
    if i+1 == min(len(s1),len(t1)):
    	print('NO')
    	break
    else : i+=1

### FIXED CODE ###

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

print(int((a+b)/2)+(a+b)%2)
n,k=map(int,input().split())
a=list(map(int,input().split()))
f=list(map(int,input().split()))
a.sort()
f.sort(reverse=True)
m=0
for i in range(n):
    m=max(m,a[i]*f[i])
x=m//2
l=0
r=m
def check(x):
    p=0
    for i in range(n):
        if x//f[i]<a[i]:
            p+=a[i]-x//f[i]
    if p>k:
        return False
    else:
        return True
while l<r:
    if check(x):
        l=x
        x=(r-l)//2
    else:
        r=x
        x=(r-l)//2
return(x)

### FIXED CODE ###

import sys
input = sys.stdin.readline
from operator import itemgetter
sys.setrecursionlimit(10000000)

a = []
f = []
n = 0

def rec(l, r, k):
    if l+1 < r:
        mid = (l + r) // 2
        s = 0
        for i in range(n):
            s += max(a[i] - mid // f[i], 0)
        if s <= k:
            return rec(l, mid, k)
        else:
            return rec(mid, r, k)
    else:
        return r

def main():
    global a, f, n
    n, k = map(int, input().strip().split())
    a = list(map(int, input().strip().split()))
    f = list(map(int, input().strip().split()))
    a = sorted(a)
    f = sorted(f, reverse=True)
    print(rec(-1, 10**12, k))

if __name__ == '__main__':
    main()
n, x, y = map(int,input().split())
dist = [0] * (n-1)
x -= 1
y -= 1
for i in range(n):
  for j in range(i+1, n):
    if (i <= x and j <= x) or (x <= i <= y and x <= j <= y) or (y <= i and y <= j):
      dist[j-i] += 1
    elif i <= x and y <= j:
      dist[j-i-(y-x)+1] += 1
    elif i <= x and x <= j <= y:
      dist[x-i + min(j-x, y-j+1)] += 1
    else:
      dist[j-y + min(y-j, j-x+1)] += 1
for d in dist:
  print(d)

### FIXED CODE ###

n, x, y = map(int,input().split())
dist = [0] * n
x -= 1
y -= 1
for i in range(n):
  for j in range(i+1, n):
    dist[min(j-i, abs(x-i)+abs(y-j)+1, abs(y-i)+abs(x-j)+1)] += 1
for d in dist[1:]:
  print(d)
class UnionFind:
    def __init__(self, n):
        self.par = [i for i in range(n+1)]
        self.rank = [0] * (n+1)

    # 検索
    def find(self, x):
        if self.par[x] == x:
            return x
        else:
            self.par[x] = self.find(self.par[x])
            return self.par[x]

    # 併合
    def union(self, x, y):
        x = self.find(x)
        y = self.find(y)
        if self.rank[x] < self.rank[y]:
            self.par[x] = y
        else:
            self.par[y] = x
            if self.rank[x] == self.rank[y]:
                self.rank[x] += 1

    # 同じ集合に属するか判定
    def same_check(self, x, y):
        return self.find(x) == self.find(y)
      
      
uf = UnionFind()
n, m = map(int,input().split())
for i in range(m):
  x, y, z = map(int,input().split())
  uf.union(x,y)
  
  
a = [0]*n
for i in range(n):
  a[uf.find[i]] += 1
  
print(n-a.count('0'))
  

### FIXED CODE ###

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

par = [i for i in range(n+1)]
rank = [0] * (n+1)

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

def unite(x,y):
  root_x = find(x)
  root_y = find(y)
  if rank[root_x] != rank[root_y]:
    par[min(root_x,root_y)] = max(root_x,root_y)
  else:
    par[root_y] = root_x
    rank[root_x] += 1


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

for i in range(n):
  roo.append(find(i+1))

print(len(set(roo))-1)
a = int(input())
b = list(map(int,input().split()))
c = 0
for i in range(0,a-1):
  c += 1/b[i]
print(1/c)

### FIXED CODE ###

a = int(input())
b = list(map(int,input().split()))
c = 0
for i in range(a):
  c += 1/b[i]
print(1/c)
N, C, K = map(int, input().split())
T = []
for i in range(N):
    T.append(int(input()))

T.sort()
i = 0
start = 0
ans = 0
limit = C
for i in range(N):
    if T[start] + K >= T[i + 1] and limit > 1 :
        limit -= 1
    elif T[start] + K < T[i + 1] and limit > 1:
        ans += 1
        limit = C
        start = i + 1
    elif T[start] + K >= T[i + 1] and limit == 1:
        ans += 1
        limit = C
        start = i + 1
if start != N:
    ans += 1
print(ans)

### FIXED CODE ###

N, C, K = map(int, input().split())
T = []
for i in range(N):
    T.append(int(input()))

T.sort()
i = 0
start = 0
ans = 0
limit = C
for i in range(N - 1):
    if T[start] + K >= T[i + 1] and limit > 1 :
        limit -= 1
    elif T[start] + K < T[i + 1] and limit > 1:
        ans += 1
        limit = C
        start = i + 1
    elif limit == 1:
        ans += 1
        limit = C
        start = i + 1
if start != N:
    ans += 1
print(ans)
S = input()
if S[2] == S[3] and S[4] == S[5]:
  print('Yes')
else:
  pirnt('No')

### FIXED CODE ###

S = input()
if S[2] == S[3] and S[4] == S[5]:
  print('Yes')
else:
  print('No')
N, K = map(int, input().split())
A = list(map(int, input().split()))

def check(lst):
    # print (set(lst))
    if (N == lst[0]) and (len(set(lst[:-1])) == 1):
        return True
    else:
        return False

def move(lst):
    tmp = [0] * (N + 1)
    for i in range(N):
        a = lst[i]
        left = max(0, i - a)
        right = min(N, i + a + 1)
        tmp[left] += 1
        tmp[right] -= 1
    for i in range(N):
        tmp[i + 1] += tmp[i]
    return tmp

for i in range(K):
    A = move(A)
    if check(A):
        # print (i)
        break

print (*A[:-1])


### FIXED CODE ###

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

a = int(A)
N = len(B)
b = 100 * int(B[:N - 3]) + int(B[N - 2:])

# print (a, b)

ans = a * b // 100

print (ans)
s = input()
list0 = ['A', 'C', 'G', 'T']
list1 = []
frag = 0
for i in s:
  if i in list0:
    frag += 1
  else:
    if frag != 0:
      list1.append(frag)
    frag = 0
print(max(list1))

### FIXED CODE ###

s=input()
count=0
count_list=[]
seq=["A","T","G","C"]
for base in s:
    if base in seq:
        count +=1
    else:
        count_list.append(count)
        count = 0
    count_list.append(count)
print(max(count_list))
a, b, x = [int(x) for x in input().split()]
a //= x
b = (b + x - 1)//b
print(b - a + 1)


### FIXED CODE ###

a, b, x = [int(x) for x in input().split()]
a = (a + x - 1)//x
b //= x
print(b - a + 1)
# C
import functools
def gcd(a,b):
    if a<b:a,b=b,a
    if a%b==0:return b
    return gcd(b,a%b)

n = int(input())
a = list(map(int, input().split()))
a.sort()
ans = 0
pre_a = -1

for i in range(n):
    if pre_a != a[i]:
        if len(a[:i]) >= 1 and len(a[i+1:] >= 1):
            res = gcd(functools.reduce(gcd, a[:i]), functools.reduce(gcd, a[i+1:]))
        else:
            values = a[:i] + a[i+1:]
            res = functools.reduce(gcd, values)
        ans = max(ans, res)
    pre_a = a[i]
print(ans)


### FIXED CODE ###

# C
import functools
# 3.4以前は math の gcd が対応していないので fractions のものを使う
# from fractions import gcd
def gcd(a,b):
    if a<b:a,b=b,a
    if a%b==0:return b
    return gcd(b,a%b)


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

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

for i in range(1,n):
    if gcd_right[i-1] != 1:
        res = gcd(gcd_right[i-1], a[-(i+1)])
    else:
        res = 1
    gcd_right.append(res)
gcd_right = gcd_right[::-1]


ans = 0
for i in range(n):
    if i == 0:
        res = gcd_right[1]
    elif i == n-1:
        res = gcd_left[-2]
    else:
        res = gcd(gcd_right[i+1], gcd_left[i-1])
    ans = max(res, ans)
print(ans)
def start(S,T):
    for x in range(len(S)-(len(T)-1)):
        if (S[x] == T[0] and (S[x+(len(T)-1)] == (T[len(T)-1]) or (S[x+(len(T)-1)] == '?'))):
            return x
    return len(S)

def delete(A,code):
    for x in range(len(code)):
        if code[x] in A:
            A.remove(code[x])
    return A
    

S = input()
T = input()
code = ''
left = list(map(chr, range(97, 123)))
if (len(S)-(len(T)-1) > 0):
    startingpoint = start(S,T)
    if (startingpoint == len(S)):
        print('UNRESTORABLE')
    else:
        if (S[0] != '?'):  
            code = S[:startingpoint] + T + S[startingpoint+(len(T))]
        else:
            code = S[:startingpoint] + T + S[startingpoint+(len(T)):]
        left = delete(left,code)
        for x in range(len(code)):
            if (code[x] == '?'):
                if (code[0] != '?'):  
                    code = code[:x] + left[x] + code[x+1:]
                else:
                    code = code[:x] + left[x] + code[x+1:]
                left.remove(left[x])
        print(code)
else:
    print('UNRESTORABLE')


### FIXED CODE ###

def search(S,T):
    match = 0
    maxmatch = 0
    maxmatchloc = -1
    for x in range(len(S)-(len(T)-1)):
        match = 0
        if (S[x] == T[0] or S[x] == '?'):
            for i in range(0,len(T)):
                ##print(S[x+i] + '-' + T[i])
                if (S[x+i] == T[i] or S[x+i] == "?"):
                    match += 1
                else:
                    ##print("Entered!")
                    match = 0
                    break
            if (match >= maxmatch and match != 0):
                ##print("ENTERED")
                maxmatchloc = x
                maxmatch = match
        ##print('At x = ' + str(x) + ': maxmatchlocation is ' + str(maxmatchloc) + ' match is ' + str(match) + ' maxmatch is' + str(maxmatch))
    return maxmatchloc

S = input()
T = input()
code = S
if '?' in S:
    if (len(T) <= len(S)):
        startpoint = search(S,T)
        for x in range(len(S)):
            if (S[x] == '?'):
                code = code[:x] + 'a' + code[x+1:] 
        if(startpoint >= 0):
            code = code[:startpoint] + T + code[startpoint + len(T):]
            print(code)
        else:
            print('UNRESTORABLE')
    else:
        print('UNRESTORABLE')
else:
    print(S)
a,b = input()
print(a*b)

### FIXED CODE ###

a,b = map(int, input().split())
print(a*b)
import sys
input = sys.stdin.readline
 
N, M = (int(i) for i in input().split())
input_list = [[int(i) for i in input().split()] for i in range(M)] 
 
m_list = [[] for j in range(N+1)]
 
for inputs in input_list:
    m_list[inputs[0]].append(inputs[1])
 
for arr in m_list:
    arr.sort()
    arr.insert(-10000)
 
for inputs in input_list:
    num = m_list[inputs[0]].index(inputs[1])
    print(str(inputs[0]).zfill(6) + str(num).zfill(6))

### FIXED CODE ###

import sys
input = sys.stdin.readline
 
N, M = (int(i) for i in input().split())
py_list = [[int(i) for i in input().split()] + [0] for i in range(M)] 
m_list = [[] for j in range(N+1)]
 
sorted_py_list = sorted(py_list, key=lambda x:x[1])

city_list = {}
for py in sorted_py_list:
    city_list[py[0]] = city_list[py[0]]+1 if py[0] in city_list else 1
    py[2] = city_list[py[0]]
 
for py in py_list:
    print(str(py[0]).zfill(6) + str(py[2]).zfill(6))
from collections import deque
S=input()
deque_S=deque(S)
flag=0
ans=0
while True:
    if deque_S[0] == deque_S[-1]:
        deque_S.pop()
        deque_S.popleft()
    else:
        if deque_S[0] == 'x':
            ans+=1
            deque_S.pop()
        elif deque_S[-1] == 'x':
            ans+=1
            deque_S.popleft()
        else:
            flag=1
            break
    if len(deque_S)<=1:
        break
if flag==1:
    print(-1)
else:
    print(ans)


### FIXED CODE ###

from collections import deque
S=input()
deque_S=deque(S)
flag=0
ans=0
while True:
    if len(deque_S)<=1:
        break
    if deque_S[0] == deque_S[-1]:
        deque_S.pop()
        deque_S.popleft()
    else:
        if deque_S[0] == 'x':
            ans+=1
            deque_S.popleft()
        elif deque_S[-1] == 'x':
            ans+=1
            deque_S.pop()
        else:
            flag=1
            break
if flag==1:
    print(-1)
else:
    print(ans)
def penki(n, k):
    return k*(k-1)**(n-1)

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

print(penki(n, k))

### FIXED CODE ###


def penki(a, b, c):
  if a==b and b==c:
    return 1
  elif a!=b and b!=c and c!=a:
    return 3
  else:
    return 2

a,b,c=map(int, input().split())
print(penki(a, b, c))
H, N = map(int, input().split())
A = [int(x) for x in input().split()]
list2 = sorted(A, reverse=True)  # reverseをTrueに
if N>0:
    del list2[0:N]
    print(sum(list2))
elif N<0:
    print(sum(A))

### FIXED CODE ###

H, A= map(int, input().split())
count=0
while H>0:
    H=H-A
    count=count+1


print(count)
a, b = [int(x) for x in input().split()]
num = '0123456789'
S = input()
flg = True
for i in len(S):
  if i == A:
    if not S[i] == '-':
      flg = False
  else:
    if not S[i] in num:
      flg = False
print('Yes' if flg else 'No')

### FIXED CODE ###

a, b = [int(x) for x in input().split()]
num = '0123456789'
S = input()
flg = True
for i in range(len(S)):
  if i == a:
    if not S[i] == '-':
      flg = False
  else:
    if not S[i] in num:
      flg = False
print('Yes' if flg else 'No')
X = int(input())

import math

Yokin = 100
Nen = 0

while X > Yokin
	Yokin = math.floor(Yokin * 1.01)
	Nen = Nen + 1

print( Nen )

### FIXED CODE ###

import math
X = int((input() .split())[0])
Yokin = 100
Nen = 0

while X > Yokin:
	Yokin = math.floor(Yokin * 1.01)
	Nen = Nen + 1

print( Nen )
a = input().split(" ")
if a[0] < a[1] and a[1] < a[2]:
    print("Yes")
else:
    print("No")a = input().split(" ")


### FIXED CODE ###

a = input().split(" ")
if a[0] < a[1] and a[1] < a[2]:
    print("Yes")
else:
    print("No")
A,B = map(int,input().split())
print((A*(B*100))//100)

### FIXED CODE ###

from decimal import Decimal
A,B = input().split()
print(int(Decimal(A)*Decimal(B)))
a= input()
b=input()
if (a==b):
  print('Yes')
else:
  print('No')


### FIXED CODE ###

from sys import stdin
a, b = stdin.readline().rstrip().split()
if (a==b):
  print('Yes')
else:
  print('No')
x = input().split()
if x >= 30:
    print("Yes")
else:
    print("No")

### FIXED CODE ###

x = int(input())
if x >= 30:
    print("Yes")
else:
    print("No")
n,k= map(int,input().split())
h = list(map(int,input().split()))
h.sort()
if n<=k:
  print(0)
else:
  a = h[0:n-k]
  print(sum(a))

### FIXED CODE ###

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

ans = 0

while H>0:
	ans += 1
	H -= A

print(ans)
Iimport math as mt
import sys
I=lambda:list(map(int,input().split()))
n,k=I()
l=sorted(I())
print(sum(l[:k]))


### FIXED CODE ###

I=lambda:list(map(int,input().split()))
n,k=I()
l=sorted(I())
print(sum(l[:k]))
X=int(input())
for i in range(X):
    if X<=(i+1)*i//2:
        ans=i
        break
print(ans)

### FIXED CODE ###

X=int(input())
i=0
while X>0:
    X-=i+1
    i+=1
print(i)
N = int(input())

H = list(list(map(int,input().split())) for _ in range(N))

#sub problem: max cost from 0 to ith day
def rec(i, choice):
  if i == len(H):
    return 0
  return max(H[i][j] + rec(i+1,j) for j in range(3) if j != choice)
print(max(rec(0, j) for j in range(3)))

### FIXED CODE ###

import sys
sys.setrecursionlimit(10000000)
 
N = int(input())
H = list(list(map(int,input().split())) for _ in range(N))
#sub problem: max cost from 0 to ith day
memo = {}
def rec(i, choice):
  if (i, choice) in memo:
    return memo[(i, choice)]
  if i == len(H):
    return 0
  m = max(H[i][j] + rec(i+1,j) for j in range(3) if j != choice)
  memo[(i, choice)] = m
  return m
print(max(rec(0, j) for j in range(3)))