Harryxun/stf_run huggingface dataset:
n = int(input())
c = [int(input()) for _ in range(n)]
v_c = []
for i,v in enumerate(c):
    if i > 0 and v == c[i-1]:
        continue
    v_c.append(v)

dp = [1]*(n+1)
color_cnt = [-1]*(2*10**5)
for i in range(len(v_c)-1, -1, -1):
    color = v_c[i]
    if color_cnt[color] > 0:
        # 増やす
        dp[i] = dp[i+1] + dp[color_cnt[color]]
    else:
        dp[i] = dp[i+1]
    color_cnt[color] = i
print(dp[0])


### FIXED CODE ###

n = int(input())
c = [int(input()) for _ in range(n)]
v_c = []
MOD = 10**9+7

for i,v in enumerate(c):
    if i > 0 and v == c[i-1]:
        continue
    v_c.append(v)

dp = [1]*(n+1)
color_cnt = [-1]*(2*10**5+5)
for i in range(1, len(v_c)+1):
    color = v_c[i-1]
    if color_cnt[color] > 0:
        dp[i] = dp[i-1] + dp[color_cnt[color]]
    else:
        dp[i] = dp[i-1]
    dp[i] %= MOD
    color_cnt[color] = i
print(dp[len(v_c)])
n = int(input())
suuretu = [int(x) for x in input().split()]
answer = 0

for i in suuretu:
    answer += calculate(i)

def calculate(i):
    a = 0
    while i % 2 == 0:
        i = i / 2
        a += 1

    return a


print(answer)

### FIXED CODE ###

import math
n = int(input())
a = list(map(int,input().split()))
maxlog = int(math.log2(max(a)))
answer = 0
for _ in range(maxlog):
  a = [aa/2 for aa in a if aa%2==0]
  answer+= len(a)
  if not a:
    break
print(answer)
S, T = input().split()
print("Yes" if S == T[:-1] else "No")


### FIXED CODE ###

S = input()
T = input()
print("Yes" if S == T[:-1] else "No")
c = input()
if c == 'a' ot c == 'i' or c == 'u' or c == 'e' or c == 'o':
  print('voel')
else:
  print('consonant')

### FIXED CODE ###

c = input()
if c == 'a' or c == 'i' or c == 'u' or c == 'e' or c == 'o':
  print("vowel")
else:
  print("consonant")
# get Alice's card A and Bob's card B
a, b = map(int, raw_input().split())

# adjust for card strength, 1 > 13
if a == 1:
	a = 14
if b == 1:
	b = 14

if a > b:
	print ("Alice")
elif a < b:
	print ("Bob")
else:
	print ("Draw")

### FIXED CODE ###

# get Alice's card A and Bob's card B
a, b = map(int, raw_input().split())

# adjust for card strength, 1 > 13
if a == 1:
	a = 14
if b == 1:
	b = 14

if a > b:
	print ("Alice")
elif a < b:
	print ("Bob")
else:
	print ("Draw")
#!/usr/bin/env python
# -*- coding: utf-8 -*-

# RemainingBalls
s, t = input().split()
a, b = map(int, input().split())
u = input()

if s == u:
    print(a-1, b)
elif t == u:
    print(a, b-1)


### FIXED CODE ###

#!/usr/bin/env python
# -*- coding: utf-8 -*-

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

if h % a == 0:
    print(h // a)
else:
    print(h//a + 1)
def read_input():
    n = int(input())
    tlist = []
    for i in range(n):
        tlist.append(int(input()))

    return n, tlist


def mygcd(a, b):
    if b == 0:
        return a
    return mygcd(b, a % b)


def mylcm(a, b):
    g = mygcd(a, b)
    return int(a * b / g)


def submit():
    n, tlist = read_input()

    acc = 1
    for t in tlist:
        acc = mylcm(acc, t)

    print(acc)

if __name__ == '__main__':
    submit()

### FIXED CODE ###



def read_input():
    n = int(input())
    tlist = []
    for i in range(n):
        tlist.append(int(input()))

    return n, tlist


def mygcd(a, b):
    if b == 0:
        return a
    return mygcd(b, a % b)


def mylcm(a, b):
    g = mygcd(a, b)
    return a * b // g


def submit():
    n, tlist = read_input()

    acc = 1
    for t in tlist:
        acc = mylcm(acc, t)

    print(acc)


if __name__ == '__main__':
    submit()
n, h, w = [int(i) for i in input().split()]
r = [h <= a and w <= b for a, b in ([int(i) for i in input().split()] for _ in range(n))]
print(sum(r))

### FIXED CODE ###

import math
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
l = [a, b, c, d, e]
ans = 9
n = 0
j = 0
for i in [i % 10 for i in l]:
    if i != 0 and i < ans:
        ans = i
        n = j
    j += 1
m = l.pop(n)
r = 0
for i in l:
    r += math.ceil(i / 10) * 10
print(r + m)
n = int(input())
# l = sort(map(int, input().split()))
l = (int(x) for x in input().split()).sort()
l_sum = 0
for i in range(n-1):
	l_sum += l[i]
if l_sum > l[n-1]:
	print('Yes')
else:
	print('No')

### FIXED CODE ###

n = int(input())
l = [int(x) for x in input().split()]
l.sort()
# print(l)
l_sum = 0
for i in range(n-1):
	l_sum += l[i]
if l[n-1] < l_sum:
	print('Yes')
else:
	print('No')
N,M = map(int,input().split())
A = list(map(int,input().split()))

R = [A[0]%M]

for i in range(1,N):
  R.append((R[-1]+A[i])%M)
  
  
k = set(R)
dic = {i:0 for i in k}
for item in R:
  dic[item]+=1


#print(dic)
ans = dic[0]*(dic[0]+1)/2
for i in k:
  if i !=0 :
    ans += dic[i]*(dic[i]-1)/2

  
print(int(ans))


### FIXED CODE ###

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

R = [A[0]%M]


for i in range(1,N):
  R.append((R[-1]+A[i])%M)



import collections
c = collections.Counter(R)


ans = 0
for key in c:
  if key == 0:
    ans += (c[key]*(c[key]+1))/2
  else:
    ans += (c[key]*(c[key]-1))/2
  



print(int(ans))
N, M, K = map(int, input().split())
2 A = list(map(int, input().split()))
3 B = list(map(int, input().split()))
4
5 a,b=[0],[0]
 6 for 7
8 for 9
i in range(N): a.append(a[i] + A[i]) i in range(M): b.append(b[i] + B[i])
10
11 ans,j=0,M
12 for 13
14
15
i in range(N + 1): ifa[i]>K:
break
while b[j] > K - a[i]:
j -= 1
ans = max(ans, i + j)
16
17
18 print(ans)

### FIXED CODE ###

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

SumA=[0 for _ in range(N+1)]
SumB=[0 for _ in range(M+1)]
for i in range(1,N+1):
    SumA[i]=SumA[i-1]+A[i-1]
for i in range(1,M+1):
    SumB[i]=SumB[i-1]+B[i-1]

def binary_search(Time,IndexA):
    if Time>K:
        return 0 
    l=0
    r=M
    c=(l+r)//2
    while r-l>1:
        if Time+SumB[c]>K: r=c
        if Time+SumB[c]<=K: l=c
        c=(l+r)//2
    if Time+SumB[r]>K: IndexB=l
    else: IndexB=r
    NumOfBooks=IndexA+IndexB
    return NumOfBooks

MaxNumOfBooks=0
for IndexA in range(N+1):
    NumOfBooks=binary_search(SumA[IndexA],IndexA)
    if MaxNumOfBooks<NumOfBooks: MaxNumOfBooks=NumOfBooks
print(MaxNumOfBooks)
# -*- coding: utf-8 -*-
import sys
from collections import defaultdict, deque

H,W=map(int, sys.stdin.readline().split())
CH,CW=map(int, sys.stdin.readline().split())
CH-=1
CW-=1
DH,DW=map(int, sys.stdin.readline().split())
DH-=1
DW-=1
S=[ sys.stdin.readline().strip() for _ in range(W) ]

D=[(0,1),(0,-1),(1,0),(-1,0)]
WARP=[]
for dh in range(-2,3):
    for dw in range(-2,3):
        if abs(dh)+abs(dw)<=1: continue
        WARP.append((dh,dw))

visit1=defaultdict(lambda: 0) #未訪問:0 訪問済み:1
visit2=defaultdict(lambda: 0) #未訪問:0 訪問済み:1

d=defaultdict(lambda: float("inf")) #スタート地点から各マスまでの距離

q=deque()
q.append((CH,CW))
d[(CH,CW)]=0

while q:
    fro_h, fro_w=q.popleft()
    #歩いて移動
    for dh,dw in D:
        to_h, to_w=fro_h+dh, fro_w+dw
        if 0<=to_h<H and 0<=to_w<W and S[to_h][to_w]=="." and visit1[(to_h, to_w)]==0:
            visit1[(to_h, to_w)]=1
            d[(to_h, to_w)]=d[(fro_h, fro_w)]
            q.appendleft((to_h, to_w))
    #ワープ
    for dh,dw in WARP:
        to_h, to_w=fro_h+dh, fro_w+dw
        if 0<=to_h<H and 0<=to_w<W and S[to_h][to_w]=="." and visit2[(to_h, to_w)]==0:
            if d[(fro_h, fro_w)]+1 < d[(to_h, to_w)]:
                visit2[(to_h, to_w)]=1
                d[(to_h, to_w)]=d[(fro_h, fro_w)]+1
                q.append((to_h, to_w))

if d[(DH,DW)]==float("inf"):
    print -1
else:
    print d[(DH,DW)]

### FIXED CODE ###

# -*- coding: utf-8 -*-
import sys
from collections import defaultdict, deque

H,W=map(int, sys.stdin.readline().split())
CH,CW=map(int, sys.stdin.readline().split())
CH-=1
CW-=1
DH,DW=map(int, sys.stdin.readline().split())
DH-=1
DW-=1
S=[ sys.stdin.readline().strip() for _ in range(H) ]

D=[(0,1),(0,-1),(1,0),(-1,0)]
WARP=[]
for dh in range(-2,3):
    for dw in range(-2,3):
        if abs(dh)+abs(dw)<=1: continue
        WARP.append((dh,dw))

d=defaultdict(lambda: float("inf")) #スタート地点から各マスまでの距離

q=deque()
q.append((0,CH,CW))
d[(CH,CW)]=0

while q:
    kyori, fro_h, fro_w=q.popleft()
    if d[(fro_h, fro_w)]<kyori: continue
    #歩いて移動
    for dh,dw in D:
        to_h, to_w=fro_h+dh, fro_w+dw
        if 0<=to_h<H and 0<=to_w<W and S[to_h][to_w]==".":
            if kyori < d[(to_h, to_w)]:
                d[(to_h, to_w)]=kyori
                q.appendleft((kyori, to_h, to_w))
    #ワープ
    for dh,dw in WARP:
        to_h, to_w=fro_h+dh, fro_w+dw
        if 0<=to_h<H and 0<=to_w<W and S[to_h][to_w]==".":
            if kyori+1 < d[(to_h, to_w)]:
                d[(to_h, to_w)]=kyori+1
                q.append((kyori+1, to_h, to_w))

if d[(DH,DW)]==float("inf"):
    print -1
else:
    print d[(DH,DW)]
import sys
if sys.version_info[0] == 2:
    input = raw_input
#sys.setrecursionlimit(2 ** 31 -1)

res = None
G = None

def dfs(jibun_v, p, jibun_c):
    global res
    global G

    res[jibun_v] = jibun_c
    #print(jibun_v, p, jibun_c)

    tonari_nodes = G[jibun_v]
    for tonari_v, w in tonari_nodes:
        #if tonari_v == p: # only no loop
        #if tonari_v == p or res[tonari_v] != -1:
        if res[tonari_v] != -1:
            continue

        else:
            if w % 2 == 0:
                tonari_c = jibun_c
            else:
                tonari_c = 1 - jibun_c

            dfs(tonari_v, jibun_v, tonari_c)
    

def main():
    N= int(input())

    global G
    G = [[] for _ in range(N)]

    for i in range(N-1):
        u, v, w = map(int, input().split(" "))
        u -= 1
        v -= 1
        w = w % 2
        G[u].append([v, w])
        G[v].append([u, w])

    global res
    res = [-1 for _ in range(N)]
    
    jibun_v = 0
    p = -1
    jibun_c = 0
    dfs(jibun_v, p, jibun_c)

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

main()
        

### FIXED CODE ###

import sys
if sys.version_info[0] == 2:
    input = raw_input
sys.setrecursionlimit(2 ** 31 -1)

res = None
G = None

def dfs(jibun_v, p, jibun_c):
    global res
    global G

    res[jibun_v] = jibun_c
    #print(jibun_v, p, jibun_c)

    tonari_nodes = G[jibun_v]
    for tonari_v, w in tonari_nodes:
        #if tonari_v == p: # only no loop
        #if tonari_v == p or res[tonari_v] != -1:
        if res[tonari_v] != -1:
            continue

        else:
            if w % 2 == 0:
                tonari_c = jibun_c
            else:
                tonari_c = 1 - jibun_c

            dfs(tonari_v, jibun_v, tonari_c)
    

def main():
    N= int(input())

    global G
    G = [[] for _ in range(N)]

    for i in range(N-1):
        u, v, w = map(int, input().split(" "))
        u -= 1
        v -= 1
        w = w % 2
        G[u].append([v, w])
        G[v].append([u, w])

    global res
    res = [-1 for _ in range(N)]
    
    jibun_v = 0
    p = -1
    jibun_c = 0
    dfs(jibun_v, p, jibun_c)

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

main()
def execute(key: int, base: str) -> str:
  s = ""
  for i in range(key):
    s += str(base)
  return s

a, b = input().split()
c = [execute(a, b), execute(b, a)]
print(sorted(c)[0])

### FIXED CODE ###

def execute(key: int, base: str) -> str:
  s = ""
  for i in range(key):
    s += str(base)
  return s

a, b = input().split()
c = [execute(int(a), b), execute(int(b), a)]
print(sorted(c)[0])
A=int(input())
B=int(input())
x=A*B
print(x)


### FIXED CODE ###

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

x=a*b
print(x)
def op_print(data,a,b):
    for i in range(a,b+1):
        print(data[i])
def op_reverse(data,a,b):
    return data[:a] + data[::-1][-b:-a] + data[:b]
def op_replace(data,a,b,q):
    return data.replace(data[a:b],q) 

data = input()
q = int(input())
for _ in range(q):
    op = list(map(str,input().split()))
    if(op[0] == "print"):
        op_print(data,int(num[0]),int(num[1]))
    elif(op[0] == "reverse"):
        data = op_reverse(data,int(num[0]),int(num[1]))
    elif(op[0] == "replace"):
        data = op_replace(data,int(num[0]),int(num[1]),num[2])


### FIXED CODE ###

s=input()
for _ in range(int(input())):
    o=input().split()
    a,b=map(int,o[1:3]);b+=1
    c=o[0][2]
    if c=='p':s=s[:a]+o[3]+s[b:]
    elif c=='i':print(s[a:b])
    elif c=='v':s=s[:a]+s[a:b][::-1]+s[b:]
import functools
dicte = {1:2, 2:5, 3:5, 4:4, 5:5, 6:6, 7:3, 8:7, 9:6}
n, m = map(int, input().split())
arr = list(map(int, input().split()))
dp = {}
def cast(a, b):
    return int(str(a)+str(b))
dp = {}
def solve(curn):
    maxi = -1
    if curn in dp:
        return dp[curn]
    if curn in dicte.values():
        for j in arr:
            if curn - dicte[j] == 0:
                maxi = max(j, maxi)
        if maxi == -1:
            return None
        dp[curn] = maxi
        return maxi
    for j in arr:
        if curn - dicte[j] >= 0:
            z = solve(curn-dicte[j])
            if z == None:
                maxi = max(j, maxi)
            else:
                maxi = max(cast(j, solve(curn - dicte[j])), maxi)
    if maxi == -1:
        return None
    dp[curn] = maxi
    return maxi
print(solve(n))

### FIXED CODE ###

a, b = map(int, input().split())
if b % a == 0:
    print(a+b)
else:
    print(b-a)
s=[int(input()) for i in range(2)]
elif s[0]+s[1]==3:
	print("3")
elif s[0]+s[1]==4:
	print("2")
elif s[0]+s[1]==5:
	print("1")
else:
	print("error")

### FIXED CODE ###

s=[int(input()) for i in range(2)]
if s[0]+s[1]==3:
	print("3")
elif s[0]+s[1]==4:
	print("2")
elif s[0]+s[1]==5:
	print("1")
else:
	print("error")
N = int(input())

chars = "0abcdefghijklmnopqrstuvwxyz"
a = ""
n = N

while True:
    x = n_1 % 26

    if x == 0:
        x = 26

    a += chars[x]
    n_1 -= x
    if n_1 == 0:
        break

    n //= 26

print(n[::-1])

### FIXED CODE ###

n = int(input())
chars = "Xabcdefghijklmnopqrstuvwxyz"  

n_rem = n  
res = ""

while True:
    x = n_rem % 26
   
    if x == 0:
        x = 26
    res += chars[x]

    
    n_rem -= x

    
    if n_rem == 0:
        break

    n_rem //= 26


print(res[::-1])
from collections import deque
import sys
input = sys.stdin.readline

n, m = map(int, input().split())
G = [[] for _ in range(n+1)]
for _ in range(m):
    u, v, s = map(int, input().split())
    G[u].append((v, s))
    G[v].append((u, s))
queue = deque([1])
color = [-1] * (n+1)
color[1] = 0
ok = True
while queue:
    u = queue.popleft()
    for v, s in G[u]:
        if color[v] == -1:
            color[v] = 1 - color[u]
            queue.append(v)
        elif color[u] == color[v]:
            ok = False
            break
    assert ok
val = [None] * (n+1)
val[1] = (1, 0)
queue = deque([1])
while queue:
    u = queue.popleft()
    for v, s in G[u]:
        if val[v] is None:
            val[v] = (-val[u][0], s - val[u][1])
            queue.append(v)
ma = float('inf')
mi = 1
x = -1
for u in range(1, n+1):
    if val[u][0] == -1:
        ma = min(ma, val[u][1] - 1)
    else:
        mi = max(mi, -val[u][1] + 1)
    for v, s in G[u]:
        if u > v:
            continue
        if val[u][0] + val[v][0] == 0:
            if val[u][1] + val[v][1] != s:
                print(0)
                exit()
        else:
            a = val[u][0] + val[v][0]
            b = s - (val[u][1] + val[v][1])
            if a < 0:
                b *= -1
            if b <= 0 or b % 2 == 1:
                print(0)
                exit()
            if x == -1:
                x = b // 2
            elif x != b // 2:
                print(0)
                exit()
if x != -1:
    print(1)
else:
    print(max(ma - mi + 1, 0))

### FIXED CODE ###

from collections import deque
import sys
input = sys.stdin.readline

n, m = map(int, input().split())
G = [[] for _ in range(n+1)]
for _ in range(m):
    u, v, s = map(int, input().split())
    G[u].append((v, s))
    G[v].append((u, s))
val = [None] * (n+1)
val[1] = (1, 0)
queue = deque([1])
while queue:
    u = queue.popleft()
    for v, s in G[u]:
        if val[v]:
            continue
        val[v] = (-val[u][0], s - val[u][1])
        queue.append(v)
ma = float('inf')
mi = 1
x = -1
for u in range(1, n+1):
    if val[u][0] == -1:
        ma = min(ma, val[u][1] - 1)
    else:
        mi = max(mi, -val[u][1] + 1)
    for v, s in G[u]:
        if u > v:
            continue
        if val[u][0] + val[v][0] == 0:
            if val[u][1] + val[v][1] != s:
                print(0)
                exit()
        else:
            a = val[u][0] + val[v][0]
            b = s - (val[u][1] + val[v][1])
            if a < 0:
                b *= -1
            if b <= 0 or b % 2 == 1:
                print(0)
                exit()
            if x == -1:
                x = b // 2
            elif x != b // 2:
                print(0)
                exit()
if x != -1:
    if mi <= x <= ma:
        print(1)
    else:
        print(0)
else:
    print(max(ma - mi + 1, 0))
a,b=map(input().split())

if a<b:
  print("<")
elif a>b:
  print(">")
else:
  print("=")


### FIXED CODE ###

a,b=input().split()

if a<b:
  print("<")
elif a>b:
  print(">")
else:
  print("=")
n = input()
k = int(input())

dp1 = [ [ i+1 for i in range(9) ] for i in range(201)]
dp2 = [ [ 0 for i in range(9) ] for i in range(201)]
dp3 = [ [ 0 for i in range(9) ] for i in range(201)]

for i in range(200):
    for j in range(9):
        if j == 0:
            dp1[i+1][j] = dp1[i][-1] + 1
        else:
            dp1[i+1][j] = dp1[i+1][j-1] + 1

for i in range(200):
    for j in range(9):
        if j == 0:
            dp2[i+1][j] = dp2[i][-1] + 9 * (i)
        else:
            dp2[i+1][j] = dp2[i+1][j-1] + 9 * (i+1)

for i in range(200):
    for j in range(9):
        if j == 0:
            dp2[i+1][j] = dp2[i][-1] + 9 * (i)
        else:
            dp2[i+1][j] = dp2[i+1][j-1] + 9 * (i+1)

for i in range(100):
    for j in range(9):
        if j == 0:
            dp3[i+1][j] = dp3[i][-1] + 81 * i*(i-1)//2
        else:
            dp3[i+1][j] = dp3[i+1][j-1] + 81 * (i+1) * i //2


def solve(s, x):
    if s[0] == "0":
        return 0
    if x == 1:

        return  dp1[len(s)-1][int(s[0]) - 1]
    elif x == 2:

        return  dp2[len(s)-1][int(s[0]) - 1] + solve(s[1:], 1)
    elif x == 3:

        return  dp3[len(s)-1][int(s[0]) - 1] + solve(s[1:], 2)

print(solve(n, k))

### FIXED CODE ###

n = input()
k = int(input())

dp1 = [ [ i+1 for i in range(9) ] for i in range(201)]
dp2 = [ [ 0 for i in range(9) ] for i in range(201)]
dp3 = [ [ 0 for i in range(9) ] for i in range(201)]

for i in range(200):
    for j in range(9):
        if j == 0:
            dp1[i+1][j] = dp1[i][-1] + 1
        else:
            dp1[i+1][j] = dp1[i+1][j-1] + 1

for i in range(200):
    for j in range(9):
        if j == 0:
            dp2[i+1][j] = dp2[i][-1] + 9 * (i)
        else:
            dp2[i+1][j] = dp2[i+1][j-1] + 9 * (i+1)

for i in range(200):
    for j in range(9):
        if j == 0:
            dp2[i+1][j] = dp2[i][-1] + 9 * (i)
        else:
            dp2[i+1][j] = dp2[i+1][j-1] + 9 * (i+1)

for i in range(100):
    for j in range(9):
        if j == 0:
            dp3[i+1][j] = dp3[i][-1] + 81 * i*(i-1)//2
        else:
            dp3[i+1][j] = dp3[i+1][j-1] + 81 * (i+1) * i //2


def solve(s, x):
    if s == "0":
        return 0
    elif s[0] == "0":
        return solve(s[1:], x)

    if x == 1:

        return  dp1[len(s)-1][int(s[0]) - 1]
    elif x == 2:
        if len(s) < 2:
            return 0
        return  dp2[len(s)-1][int(s[0]) - 1] + solve(s[1:], 1)
    elif x == 3:
        if len(s) < 3:
            return 0
        return  dp3[len(s)-1][int(s[0]) - 1] + solve(s[1:], 2)

print(solve(n, k))
import sys
input = sys.stdin.readline

N = int(input())
L = [[0] * 3 for _ in range(N)]

for i in range(N):
    L[i][0], L[i][1] = [int(i) for i in input().split()]
    L[i][2] = L[i][0] + L[i][1]

L.sort(key=lambda x:x[2], reverse=True)

print(sum(L[::2][0]) - sum(L[1::2][1]))

### FIXED CODE ###

N = int(input())
A = [0] * N
B = [0] * N
Sum = [[0] * 2 for i in range(N)]

for i in range(N):
    A[i], B[i] = map(int, input().split())
    Sum[i][0] = i
    Sum[i][1] = A[i] + B[i]
    
a = 0
b = 0
turn = 0

Sum.sort(key=lambda x:x[1], reverse=True)
    
for i in range(N):
    if turn == 0:
        a += A[Sum[i][0]]
        turn = 1
    else:
        b += B[Sum[i][0]]
        turn = 0

print(a - b)
k,t=wap(int,input().split())
l=list(map(int,input().split()))
print(max(0,max(l)//2-n))

### FIXED CODE ###

k,t=map(int,input().split())
l=list(map(int,input().split()))
if len(l)==1:
  print(k-1)
else:
  if k%2==0:
    print(max(0,(max(l)-k//2)*2-1))
  else:
    print(max(0,(max(l)-k//2-1)*2))
A, B = map(int,input())
if(A == B):
    print('Draw')
elif(B != 1 and (A == 1 or A > B)):
    print('Alice')
elif(A != 1 and (B == 1 or B > A)):
    print('Bob')

### FIXED CODE ###

A, B = map(int,input().split())
if(A == B):
    print('Draw')
elif(B != 1 and (A == 1 or A > B)):
    print('Alice')
elif(A != 1 and (B == 1 or B > A)):
    print('Bob')
N = int(input())
alphabets = list('zabcdefghijklmnopqrstuvwxy')

v = []
# 26進数
while True:
    N, mod = divmod(N, 26)
    if mod == 0:
        mod = 26
        N -= 1
    v.append(alphabets[mod])
    if N < 26:
        if N != 0:
            v.append(alphabets[N])
        break
v = v[::-1]
ans = ''.join(v)
print(ans)


### FIXED CODE ###

N = int(input())

# 26進数
v = []
while True:
    N, mod = divmod(N, 26)
    if mod == 0:
        mod = 26
        N -= 1
    v.append(mod)
    if N < 26:
        v.append(N)
        break
v = v[::-1]
# print('v', v)
alphabets = list('0abcdefghijklmnopqrstuvwxyz')
s = []
for i in v:
    if i == 0:
        continue
    s.append(alphabets[i])
# print('s', s)
ans = ''.join(s)
print(ans)
A,B  = input().split()
Flag = 1:

if B == '0':
    Flag = 0

if Flag 
    if B[0] == 0:
        BH =      B[2]+B[3]
    else:
        BH = B[0]+B[2]+B[3]

    ABH = str(int(A)*int(BH))
    print(int(ABH[:-2]))
else:
    print(0)

### FIXED CODE ###

A,B  = input().split()

if B[0] == 0:
    BH =      B[2]+B[3]
else:
    BH = B[0]+B[2]+B[3]

ABH = str(int(A)*int(BH))
if len(ABH) <= 2:
    print('0')
else:
    print(ABH[:-2])
x, y = [int(x) for x in input().split()]
size = int.bit_length(y/x)
if x == y:
  print(0)
else:
  print(size)

### FIXED CODE ###

x, y = [int(x) for x in input().split()]
size = int(y//x).bit_length()
print(size)
a,b = map(int, input().split())

def height(n):
    if n==1:
        return 1
    else:
        return n+height(n-1)
    
d = height(b-a)
print(d-b)

### FIXED CODE ###

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

def height(n):
    sum = 0
    for i in range(n+1):
        sum += i
    return sum
    
#    if n==1:
#        return 1
#    else:
#        return n+height(n-1)
    
d = height(b-a)
print(d-b)
h=input()

id=[i for i,k in enumerate(h) if k=="h"] 

a=0

for l in id:
  if "i"==h[l+1]:
    if "i"!=h[l+2]:
      a+=1
    elif "ii" == h[l+2]:
      a+=0
  elif "i" != h[l+1]:
    a+=0
        
if "h" not in h:
  a+=0
  
if a>0:
  print("Yes")
else:
  print("No")
    

### FIXED CODE ###

S = input()
hitachi = [
    'hi',
    'hihi',
    'hihihi',
    'hihihihi',
    'hihihihihi',
]
if S in hitachi:
    print('Yes')
else:
    print('No')