Harryxun/stf_run huggingface dataset:
N = input()
S = N % 10
if(S == 0):
  print("pon")
elif(S == 1):
  print("pon")
elif(S == 6):
  print("pon")
elif(S == 8):
  print("pon")
elif(S == 3):
  print("bon")
else:
  print("hon")

### FIXED CODE ###

N = int(input())
S = N % 10
if(S == 0):
  print("pon")
elif(S == 1):
  print("pon")
elif(S == 6):
  print("pon")
elif(S == 8):
  print("pon")
elif(S == 3):
  print("bon")
else:
  print("hon")
import numpy as np
N, M = [int(x) for x in input().split(' ')]

As = [int(x) for x in input().split(' ')]
As.sort()

Bs = []
Cs = []
for _ in range(M):
  b, c = [int(x) for x in input().split(' ')]
  Cs += [c for _ in range(b)]
if len(Cs) > N:
  Cs = Cs.sort(reverse=True)[: N+1]
else:
  Cs.sort()
  
num = 0
for i in range(len(Cs)):
  a = As[i]
  c = Cs[i]
  if a < c:
    num += c
  else:
    break
num += sum(As[i+1: ])
    
print(num)

### FIXED CODE ###

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

As = list(map(int, input().split()))
As.sort()

BCs = []
for _ in range(M):
  b, c = tuple(map(int, input().split()))
  BCs.append((b, c))
BCs.sort(key=lambda x: x[1], reverse=True)
  
num = 0
i = 0
for b, c in BCs:
  for j in range(b):
    a = As[i]
    
    if a >= c:
      break
    else:
      num += c
      i += 1
      
    if i == len(As):
      break
      
  if a >= c or i == len(As):
    break
num += sum(As[i: ])
    
print(num)
#それぞれの桁を考えた時にその桁を一つ多めに払うのかちょうどで払うのかで場合分けする

import math
n=int(input())
k=math.floor(math.log10(n))+1#桁数
n=list(map(int,str(n)))#それぞれの桁にアクセスするためにイテラブルにする

#それぞれの桁を見ていくが、そのままと一つ多い状態から引く場合と二つあることに注意
dp=[[-1,-1] for _ in range(k)]
dp[0]=[min(1+(10-n[0]),n[0]),min(1+(10-n[0]-1),n[0]+1)]
for i in range(1,k):
    dp[i]=[min(dp[i-1][1]+(10-n[i]),dp[i-1][0]+n[i]),min(dp[i-1][1]+(10-n[i]-1),dp[i-1][0]+n[i]+1)]
print(dp[k-1][0])

### FIXED CODE ###

#それぞれの桁を考えた時にその桁を一つ多めに払うのかちょうどで払うのかで場合分けする

n=[int(x) for x in list(input())]#それぞれの桁にアクセスするためにイテラブルにする
k=len(n)

#それぞれの桁を見ていくが、そのままと一つ多い状態から引く場合と二つあることに注意
dp=[[-1,-1] for _ in range(k)]
dp[0]=[min(1+(10-n[0]),n[0]),min(1+(10-n[0]-1),n[0]+1)]
for i in range(1,k):
    dp[i]=[min(dp[i-1][1]+(10-n[i]),dp[i-1][0]+n[i]),min(dp[i-1][1]+(10-n[i]-1),dp[i-1][0]+n[i]+1)]
print(dp[k-1][0])
nums = [0, 2, 5, 5, 4, 5, 6, 3, 7, 6]
N, M = map(int, input().split())
A = list(map(int, input().split()))

# 使うマッチ棒の本数が等しい場合は大きい数だけ考えれば良い
A.sort(reverse=True)
s = set()
candidates = [] # [a, nums[a]]
for a in A:
  if nums[a] in s:
    continue
  s.add(nums[a])
  candidates.append([a, nums[a]])


dp1 = [0] * (N+1)
dp2 = [-1] * (N+1)
d = {}
for a, n in candidates:
  dp1[n] = 1
  dp2[n] = 0
  d[n] = a

for i in range(N+1):
  for a, n in candidates:
    if i >= n and dp1[i-n]:
      if dp1[i] < dp1[i-n] + 1:
        dp1[i] = dp1[i-n] + 1
        dp2[i] = i-n

ans = []
idx = N
while idx:
  next_idx = dp2[idx]
  ans.append(d[idx - next_idx])
  idx = next_idx

ans.sort(reverse=True)
print(''.join(list(map(str, ans))))

### FIXED CODE ###

nums = [0, 2, 5, 5, 4, 5, 6, 3, 7, 6]
N, M = map(int, input().split())
A = list(map(int, input().split()))

# 使うマッチ棒の本数が等しい場合は大きい数だけ考えれば良い
A.sort(reverse=True)
s = set()
candidates = [] # [a, nums[a]]
for a in A:
  if nums[a] in s:
    continue
  s.add(nums[a])
  candidates.append([a, nums[a]])


dp1 = [0] * (N+1)
dp2 = [-1] * (N+1)
d = {}
for a, n in candidates:
  if n <= N:
    dp1[n] = 1
    dp2[n] = 0
    d[n] = a

for i in range(N+1):
  for a, n in candidates:
    if i >= n and dp1[i-n]:
      if dp1[i] < dp1[i-n] + 1:
        dp1[i] = dp1[i-n] + 1
        dp2[i] = i-n

ans = []
idx = N
while idx:
  next_idx = dp2[idx]
  ans.append(d[idx - next_idx])
  idx = next_idx

ans.sort(reverse=True)
print(''.join(list(map(str, ans))))
import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,random,time,queue,copy

sys.setrecursionlimit(10**7)
inf=10**20
mod=10**9+7
dd=[(-1,0),(0,1),(1,0),(0,-1)]
ddn=[(-1,0),(-1,1),(0,1),(1,1),(1,0),(1,-1),(0,-1),(-1,-1)]

def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS(): return sys.stdin.readline().split()
def S(): return input()

# GCD -- START --
def gcd(x,y):
  while y:
    x,y=y,x%y
  return x
# GCD --- END ---

# LCM -- START --
def lcm(x,y):
  return x/gcd(x,y)*y
# LCM --- END ---

def main():
  n=I()
  ans=I()

  for _ in range(n-1):
    ans=int(lcm(ans,I()))

  return ans

# main()
print(main())


### FIXED CODE ###

import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,random,time,queue,copy

sys.setrecursionlimit(10**7)
inf=10**20
mod=10**9+7
dd=[(-1,0),(0,1),(1,0),(0,-1)]
ddn=[(-1,0),(-1,1),(0,1),(1,1),(1,0),(1,-1),(0,-1),(-1,-1)]

def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS(): return sys.stdin.readline().split()
def S(): return input()

# GCD -- START --
def gcd(x,y):
  while y:
    x,y=y,x%y
  return x
# GCD --- END ---

# LCM -- START --
def lcm(x,y):
  return x*y//gcd(x,y)
# LCM --- END ---

def main():
  n=I()
  ans=I()

  for _ in range(n-1):
    ans=lcm(ans,I())

  return ans

# main()
print(main())
N = int(input())
A = int(input())
B = int(input())

if N == 1:
    print('Hello World')
if N == 2:
    print(A+B)

### FIXED CODE ###

N = int(input())


if N == 1:
    print('Hello World')
elif N == 2:
    A = int(input())
    B = int(input())
    print(A+B)
n=int(input())
s=input()
t=input()
for i in range(n):
 if s[-i-1:]==t[:i+1]:
  cnt=i+1
print(2*n-cnt)

### FIXED CODE ###

n=int(input())
s=input()
t=input()
cnt=0
for i in range(n):
 if s[-i-1:]==t[:i+1]:
  cnt=max(cnt,i+1)
print(2*n-cnt)
ans = "WA"
s = list(input())
if s[0] == "A":
  if s[2:-1].count("C") == 1:
    c = s[2:-1].index("C")
    if all([ list[i].islower() for i in range(1,len(s)) if i != c]):
      ans = "AC"
print(ans)

### FIXED CODE ###


ans = "WA"
s = list(input())
if s[0] == "A":
  if s[2:-1].count("C") == 1:
    c = s[2:-1].index("C")+2

    if all([ s[i].islower() for i in range(1,len(s)) if i != c]):
      ans = "AC"

print(ans)
print('Even' if eval(input().replace('', '*')+'%2==0') else 'Odd')

### FIXED CODE ###

print('Even' if eval(input().replace(' ', '*')+'%2==0') else 'Odd')
a, b, x = map(int, input().split())
ans = 0

def fanc(n, x):
    if n == -1:
        f = 0
    else:
        f = n // (x + 1) # 切り捨て除算//を使うとint同士ならintで返してくれるから楽
    return f
print(fanc(b, x) - fanc(a - 1, x)) 

### FIXED CODE ###

a, b, c = map(str, input().split())
abb = a[0] + b[0] + c[0]
print(abb)
n, k = map(int, input().strip().split())

prev = None

n = n % k
print(min(n, k % n))


### FIXED CODE ###

n, k = map(int, input().strip().split())

min_n = 1000000000000000000000000000
for i in range(1000):
    if n > k:
        n %= k
    n = abs(n - k)
    min_n = min(min_n, n)

print(min_n)
cache = {0: 1, 1: 1, 2: 2}


def permutuation(n):
    if n in cache:
        return cache[n]
    return n * permutuation(n - 1)


def combo(n, r):
    x = permutuation(n)
    y = permutuation(n-r)
    z = permutuation(r)
    return int(x / (y * z))


count = int(input())
li = list(map(int, input().split()))

sli = sorted(li)

pair_a = 0
pair_b = 0
current_max = 0

for i in range(1,len(sli)):
    for j in range(0, i):
        val = combo(sli[i], sli[j])
        # print(str(sli[i]) + ", " + str(sli[j]) + ", " + str(val))
        if val > current_max:
            current_max = val
            pair_a = sli[i]
            pair_b = sli[j]

print(str(pair_a) + " " + str(pair_b))

### FIXED CODE ###

count = int(input())
li = list(map(int, input().split()))

sli = sorted(li)

pair_a = sli[len(sli) - 1]
pair_b = 0
current_max = 0

i = sli[len(sli) - 1]

diff = 10**9
for j in range(0, len(sli) - 1):
    h = pair_a / 2
    if abs(h - sli[j]) < diff:
        diff = abs(h - sli[j])
        pair_b = sli[j]

print(str(pair_a) + " " + str(pair_b))
from math import gcd

n = int( input() )
a = list( map( int, input().split() ) )
left = [0]*n
right = [0]*n

left[0] = a[0]
for i in range(1,n):
    left[i] = gcd(left[i-1], a[i])

right[-1] = a[-1]
for i in range(2,n+1):
    right[-i] = gcd(right[-i+1], a[-i])

max_gcd = 0
for i in range(n):
    if i == 0 and max_gcd < right[1]:
        max_gcd = right[1]
    elif i == n-1 and max_gcd < left[n-2]:
        max_gcd = left[n-2]
    if i >= 1 and i <= n-2 and max_gcd < gcd( left[i-1], right[i+1]):
        max_gcd = gcd( left[i-1], right[i+1])

print(max_gcd) 

### FIXED CODE ###

def GCD(x, y): 
    while(y): 
       x, y = y, x % y 
    return x

n = int( input() )
a = list( map( int, input().split() ) )
left = [0]*n
right = [0]*n

left[0] = a[0]
for i in range(1,n):
    left[i] = GCD(left[i-1], a[i])

right[-1] = a[-1]
for i in range(2,n+1):
    right[-i] = GCD(right[-i+1], a[-i])

max_gcd = 0
for i in range(n):
    if i == 0 and max_gcd < right[1]:
        max_gcd = right[1]
    elif i == n-1 and max_gcd < left[n-2]:
        max_gcd = left[n-2]
    if i >= 1 and i <= n-2 and max_gcd < GCD( left[i-1], right[i+1]):
        max_gcd = GCD( left[i-1], right[i+1])

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

A = sorted(A, key=lambda x: x[0])
maxi = 2*(10**5)+1
dp = [0] * maxi

for i in range(N):
    tmp = A[i]
    if dp[tmp] != 0:
        dp[tmp] = 2
        continue
    else:
        for j in range(tmp, maxi, tmp):
            dp[j] += 1

ans = 0
for i in range(N):
    tmp = A[i]
    if dp[tmp] == 1:
        ans += 1

print(ans)

### FIXED CODE ###

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

A = sorted(A)
maxi = 10**6+1
dp = [0] * maxi

for i in range(N):
    tmp = A[i]
    if dp[tmp] != 0:
        dp[tmp] = 2
        continue
    else:
        for j in range(tmp, maxi, tmp):
            dp[j] += 1

ans = 0
for i in range(N):
    tmp = A[i]
    if dp[tmp] == 1:
        ans += 1

print(ans)
from collections import defaultdict
n = int(input())
xy = [list(map(int, input().split())) for _ in range(n)]
xy.sort()
h = defaultdict(int)
for x, y in xy:
    h[(x, y)] = True
mx, my = xy[-1]
ans = 10**10
for i in range(n-1):
    x1, y1 = xy[i]
    for j in range(i+1, n):
        x2, y2 = xy[i+1]
        z1 = x2-x1
        z2 = y2-y1

        t = set()
        k = 0
        a = 0
        while k < n and len(t) < n:
            xk, yk = xy[k]
            if (xk, yk) not in t:
                a += 1
                while xk <= mx and yk <= my:
                    if (xk, yk) in h and (xk, yk) not in t:
                        t.add((xk, yk))
                    xk += z1
                    yk += z2
            k += 1
        if a < ans:
            ans = a

print(ans)


### FIXED CODE ###

n, k = map(int, input().split())
l = [1]*k
n -= sum(l)
l[0] += n
print(max(l)-min(l))
def main():
    n = int(input())
    blis = list(map(int, input().split()))

    alis = [blis[0], blis[0]]
    if alis[1] > blis[1]:
        alis[1] = blis[1]
    if n > 2:
        for i in range(3, n):
            alis.append(min(blis[i-2], blis[i-1]))
    if n > 2:
        alis.append(blis[n-2])
    print(sum(alis))


    


if __name__ == "__main__":
    main()


### FIXED CODE ###

def main():
    n = int(input())
    blis = list(map(int, input().split()))

    alis = [blis[0], blis[0]]
    if n > 2 and alis[1] > blis[1]:
        alis[1] = blis[1]
    if n > 2:
        for i in range(3, n):
            alis.append(min(blis[i-2], blis[i-1]))
    if n > 2:
        alis.append(blis[n-2])
    print(sum(alis))


    


if __name__ == "__main__":
    main()
import math
 
def main():
  N = int(input())
  
  print(search(N))
 
def search(x):
  
  ints = list(range(2,x))
  
  # 順に確認する
  for i in ints:
    if x%i==0:
      return search(x+1)
  	elif x < i**2:
      break
    
  return x

### FIXED CODE ###

def main():
  N = int(input())
  
  print(search(N))
 
def search(x):
  
  ints = list(range(2,x))
  
  # 順に確認する
  for i in ints:
    if x%i==0:
      return search(x+1)
    elif x < i**2:
      break
    
  return x

main()
n,m = map(int,input().split())
a = [0]*n
for i in range(m):
    p,s = map(str,input().split())
    p = int(p)
    if s == "AC" and a[p-1] != -1:
        ac +=1
        wa += a[p-1]
        a[p-1] = -1
    elif s == "WA" and a[p-1] != -1:
        wa += 1
print(ac,wa)



### FIXED CODE ###

n,m = map(int,input().split())
a = [0]*n
ac,wa = 0,0
for i in range(m):
    p,s = map(str,input().split())
    p = int(p)
    if s == "AC" and a[p-1] != -1:
        ac +=1
        wa += a[p-1]
        a[p-1] = -1
    elif s == "WA" and a[p-1] != -1:
        a[p-1] += 1
print(ac,wa)
from math import gcd

N, X = map(int, input().split())
x = [abs(X-int(x)) for x in input().split()]
if N==1:
    print(x[0])
else:
    GCD = gcd(x[0],x[1])
    for i in range(2,N):
        GCD = gcd(GCD,x[i])
    print(GCD)
    

### FIXED CODE ###

# from math import gcd
def gcd(x, y):
    if y > x:
        x, y = y, x
    if y == 0:
        return x
    return gcd(y, x % y)


N, X = map(int, input().split())
x = [abs(X-int(x)) for x in input().split()]
if N == 1:
    print(x[0])
else:
    GCD = gcd(x[0], x[1])
    for i in range(2, N):
        GCD = gcd(GCD, x[i])
    print(GCD)
def main():
    N = int(input())
    X = []
    L = []
    for i in range(N):
        x, l = [int(s) for s in input().split()]
        X.append(x)
        L.append(l)

    ranges = []
    for i in range(N):
        ranges.append((X[i] - L[i], X[i] + L[i]))
    ranges.sort(key=lambda x: x[0])

    i = 0
    while True:
        if ranges[i][1] > ranges[i + 1][0]:
            ranges.pop(i + 1)
        else:
            i += 1
        if i == len(ranges) - 1:
            break
    print(len(ranges))


if __name__ == "__main__":
    main()


### FIXED CODE ###

def main():
    N = int(input())
    X = []
    L = []
    for i in range(N):
        x, l = [int(s) for s in input().split()]
        X.append(x)
        L.append(l)

    ranges = []
    for i in range(N):
        ranges.append((X[i] - L[i], X[i] + L[i]))
    ranges.sort(key=lambda x: x[1])

    cnt = len(ranges)
    end = ranges[0][1]
    for i in range(1, len(ranges)):
        if ranges[i][0] < end:
            cnt -= 1
        else:
            end = ranges[i][1]
    print(cnt)


if __name__ == "__main__":
    main()
# AGC013
N = int(input())
A = list(map(int, input().split()))
for i in range(N):
    if A[i] == A[i+1]:
        pass
    elif A[i] > A[i+1]:
        now = "N"
        break
    else:
        now = "P"
        break
ans = 1
for i in range(N-1):
    if now == "?":
        if A[i] == A[i+1]:
            pass
        elif A[i] > A[i+1]:
            now = "N"
        else:
            now = "P"
    elif now == "P":
        if A[i] <= A[i+1]:
            pass
        else:
            ans += 1
            now = "?"
    else:
        if A[i] >= A[i+1]:
            pass
        else:
            ans += 1
            now = "?"
print(ans)

### FIXED CODE ###

# AGC013
N = int(input())
A = list(map(int, input().split()))
if N == 1:
    print(1)
    exit()
for i in range(N):
    if A[i] == A[i+1]:
        pass
    elif A[i] > A[i+1]:
        now = "N"
        break
    else:
        now = "P"
        break
ans = 1
for i in range(N-1):
    if now == "?":
        if A[i] == A[i+1]:
            pass
        elif A[i] > A[i+1]:
            now = "N"
        else:
            now = "P"
    elif now == "P":
        if A[i] <= A[i+1]:
            pass
        else:
            ans += 1
            now = "?"
    else:
        if A[i] >= A[i+1]:
            pass
        else:
            ans += 1
            now = "?"
print(ans)
l = map(int, input().split())

if l[0] == l[1] == l[2]
	print("Yes")
else
	print("No")


### FIXED CODE ###

a = input().split()
if int(a[0]) == int(a[1]) and int(a[1]) == int(a[2]):
	print("Yes")
else:
	print("No")
num = int(input().split())
for i in range(6):
  if num[i] == 0:
    print(int(str(i)))

### FIXED CODE ###

num = list(input().split())
for i in range(5):
  if num[i] == "0":
    print(int(str(i + 1)))
import string
a=[]
while True:
    b=input()
    if b=="":
        break
    else:
        a=a+[str(x) for x in b.lower().replace(" ","",10000)]
dictionary={}
alphabetlist=string.ascii_lowercase
for i in "abcdefghijklmnopqrstuvwxyz":    
    counter=0
    for j in a:
        if i==j:
            counter+=1
    print(str(i)+" : "+str(counter))
    

### FIXED CODE ###

import sys
cnts = {}
for line in sys.stdin:
    for c in list(line.lower()): cnts[c] = cnts.get(c,0) + 1
  
for c in range(ord('a'),ord('z')+1): print(chr(c),':',cnts.get(chr(c),0))
n = input()

f = False

x = sum(map(int,list(n)))

if n % x == 0:
    f = True

if f:
    print("Yes")
else:
    print("No")

### FIXED CODE ###

n = int(input())

f = False

x = sum(list(map(int, str(n))))

if n % x == 0:
    f = True

if f:
    print("Yes")
else:
    print("No")
N,K = map(int,input().split())
S = input()
ans = 0
for i in range(N):
    if S[i] == S[i+1]:
        ans += 1
ans += 2*K
if ans > N-1:
    ans = N-1
print(ans)

### FIXED CODE ###

N,K = map(int,input().split())
S = input()
ans = 0
for i in range(N-1):
    if S[i] == S[i+1]:
        ans += 1
ans += 2*K
if ans > N-1:
    ans = N-1
print(ans)
N = int(input())
A = list(map(int, input().split()))
while(True):
    for i in range(N):
        if A[i] % 2 == 0:
            A[i] = A[i] / 2
        else:
            break
    ans += 1

print(ans)


### FIXED CODE ###

N = int(input())
A = list(map(int, input().split()))
ans = 0
flg = "True"

while flg == "True":
    ans += 1
    for i in range(N):
        if A[i] % 2 == 0:
            A[i] = A[i] / 2
        else:
            flg = "False"

print(ans - 1)
a,b,c,k = map(int,input().split())
 
if k <= a:
  print(a)
elif a < k and k <= a+b:
  print(a)
elif a+b < k and k <= a+b+c:
  print(a-k+a+b)

### FIXED CODE ###

s = input()
t = input()

if t[:-1] == s:
  print('Yes')
else:
  print('No')
import sys
import itertools
# import numpy as np
import time
import math

sys.setrecursionlimit(10 ** 7)

from collections import defaultdict

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

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

counter = [0 for _ in range(n + 1)]
for i in a:
    counter[i] += 1

MAX = 10 ** 5
MOD = 10 ** 9 + 7
fac = [0 for i in range(MAX)]
finv = [0 for i in range(MAX)]
inv = [0 for i in range(MAX)]

def comInit(mod):
    fac[0], fac[1] = 1, 1
    finv[0], finv[1] = 1, 1
    inv[1] = 1
    for i in range(2, MAX):
        fac[i] = fac[i - 1] * i % mod
        inv[i] = mod - inv[mod % i] * (mod // i) % mod
        finv[i] = finv[i - 1] * inv[i] % mod

def com(n, r, mod):
    if n < r:
        return 0
    if n < 0 or r < 0:
        return 0
    return fac[n] * (finv[r] * finv[n - r] % mod) % mod

comInit(MOD)

# total = 0 
# diff = [0 for _ in range(n + 1)]
for i, c in enumerate(counter):
    x = com(c, 2, MOD)
#     total += x
#     if c - 1 <= 0:
#         diff[i] = x
#     else:
#         y = com(c - 1, 2, MOD)
#         diff[i] = x - y

# for i in range(n):
#     print(total - diff[a[i]])

### FIXED CODE ###

import sys
import itertools
# import numpy as np
import time
import math

sys.setrecursionlimit(10 ** 7)

from collections import defaultdict

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

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

counter = [0 for _ in range(n + 1)]
for i in a:
    counter[i] += 1

total = 0 
diff = [0 for _ in range(n + 1)]
for i, c in enumerate(counter):
    x = c * (c - 1) // 2
    total += x
    if c - 1 <= 0:
        diff[i] = x
    else:
        y = (c - 1) * (c - 2) // 2
        diff[i] = x - y

for i in range(n):
    print(total - diff[a[i]])
group = [[1,3,5,7,8,10,12],[4,6,9,11]]

x, y = map(int, raw_input().split())
for i in range(0,1):
    if(group[i].count(x) > 0 and group[i].count(y) > 0):
        print("Yes")
        exit()
print("No")


### FIXED CODE ###

group = [[1,3,5,7,8,10,12],[4,6,9,11],[2]]

x, y = map(int, input().split())
for i in range(0,2):
    if(group[i].count(x) > 0 and group[i].count(y) > 0):
        print("Yes")
        exit()
print("No")
import math

A, B = map(int, input().split())
print(A * B // math.gcd(A, B))

### FIXED CODE ###

def gcd(x, y):
    while y > 0:
        x, y = y, x % y
    return x


A, B = map(int, input().split())
print(A * B // gcd(A, B))
# -*- coding: utf-8 -*-
import sys
import math
from bisect import bisect_left
from bisect import bisect_right
import collections
import copy
import heapq
input = sys.stdin.readline
 
# bisect_left(lists, 3)
# bisect_right(lists, 3)

# heapq.heapify(a) #リストaのheap化
# heapq.heappush(a,x) #heap化されたリストaに要素xを追加
# heapq.heappop(a) #heap化されたリストaから最小値を削除＆その最小値を出力

# heapq.heappush(a, -x) #最大値を取り出す時は、pushする時にマイナスにして入れよう
# heapq.heappop(a) * (-1) #取り出す時は、-1を掛けて取り出すこと

def main():
	N, K = map(int, input().split(" "))
	#N = int(input())
	#S = input()
	V = input().split(" ")
	V = [int(s) for s in V]

	ptn = []
	for i in range(K):
		tmp = K - i
		ptn.append((i, tmp))

	ans = 0
	for i in ptn:
		L, R = i
		tmp = 0
		for i in range(L):
			tmp += V[i]
		for i in range(R):
			tmp += V[-i-1]
		
		if tmp > ans:
			ans = tmp

	print(ans)

if __name__ == "__main__":
	main()

### FIXED CODE ###

# -*- coding: utf-8 -*-
import sys
import copy
import collections
from bisect import bisect_left
from bisect import bisect_right
	
def main():
	N, K = map(int, input().split(" "))
	V = list(map(int, input().split(" ")))
	
	V_tmp = copy.deepcopy(V)
	ans = 0
	for L in range(K+1):
		for R in range((K+1)-L):
			V = copy.deepcopy(V_tmp)
			gets = []
			tmp = 0
			
			for i in range(L):
				if len(V) > 0:
					tmptmp = V.pop(0)
					tmp += tmptmp
					if tmptmp < 0:
						gets.append(tmptmp)
					
			for i in range(R):
				if len(V) > 0:
					tmptmp = V.pop(-1)
					tmp += tmptmp
					if tmptmp < 0:
						gets.append(tmptmp)
					
			#print(gets)
			for i in range(K-L-R):
				if len(gets) == 0:
					break
				gets.sort()
				tmp = tmp + (-1 * gets.pop(0))
				
			if tmp > ans:
				ans = tmp
				
	print(ans)
	
	
	
if __name__ == "__main__":
	main()
H, W = map(int, input().split())
A = [list(map(int, input().split())) for _ in range(H)]
R = []
prev = None
for i in range(1,H+1):
    for j in range(1,W+1)[::(i&1)*2-1]:
        if prev is None:
            if A[i-1][j-1] & 1:
                prev = i, j
        else:
            R.append((*prev, i, j))
            if A[i-1][j-1] & 1:
                prev = None
            else:
                prev = i, j

print(len(R))
for r in R:
    print(*r)

### FIXED CODE ###

H, W = map(int, input().split())
A = [list(map(int, input().split())) for _ in range(H)]
C = sum(sum(a&1 for a in aa) for aa in A)
if C&1:
    for i in range(1,H+1):
        for j in range(1,W+1)[::(i&1)*2-1]:
            if A[i-1][j-1]&1:
                A[i-1][j-1]=0
                break
        else:
            continue
        break
R = []
prev = None
for i in range(1,H+1):
    for j in range(1,W+1)[::(i&1)*2-1]:
        if prev is None:
            if A[i-1][j-1] & 1:
                prev = i, j
        else:
            y, x = prev
            R.append((y, x, i, j))
            if A[i-1][j-1] & 1:
                prev = None
            else:
                prev = i, j

print(len(R))
for r in R:
    print(*r)
S = str(input())
list = lisr(S)
num = list.count('+')
print('num - (4-num)')

### FIXED CODE ###

S = str(input())
list = list(S)
num = list.count('+')
print(num - (4-num))
h, w = map(int, input().split())
return (h * w + 1)//2

### FIXED CODE ###

h, w = map(int, input().split())
if h==1 or w==1:
  print(1)
else:
  print((h*w+1)//2)