Harryxun/stf_run huggingface dataset:
x,y = input("Enter a two value: ").split()
a = int(x)
b = int(y)
for i in range(1,200000):
    if i%a == 0 and i%b ==0:
        return i
        m = i
        break
    else:
        pass

### FIXED CODE ###


x, y = input().split()
x = int(x)
y = int(y)
if x < y:
    a = y
    b = x
else:
    a = x
    b = y

while b:
    a, b = b, a % b

print(x * y // a)
from prime_factorize import prime_factorize
a,b=map(int,input().split())
print(len(set(prime_factorize(a))&set(prime_factorize(b)))+1)

### FIXED CODE ###

from collections import Counter
def prime_fact(n):
    a=[]
    while n%2==0:
        a.append(2)
        n //=2
    f=3
    while f**2<=n:
        if n%f==0:
            a.append(f)
            n //=f
        else:f +=2
    if n!=1:a.append(n)
    return a

a,b=map(int,input().split())
a_key=Counter(prime_fact(a))
b_key=Counter(prime_fact(b))
print(len(a_key&b_key)+1)
def gen_switch(i, n):
    ret = []
    str_bin = format(i, '011b')
    for k in range(n):
        ret.append(int(str_bin[-k-1]))
    ret.reverse()
    return ret


input_line = raw_input()
splitted_line = input_line.split(" ")
n = int(splitted_line[0])
m = int(splitted_line[1])


my_mtx = []

for i in range(m):
    my_list = [0] * n
    splitted_line = raw_input().split(" ")

    for j in range(len(splitted_line)):
        if j != 0:
            my_list[int(splitted_line[j])-1] = 1

    my_mtx.append(my_list)

splitted_line = raw_input().split(" ")
my_list = []

for item in splitted_line:
    my_list.append(int(item))


count = 0

# print(my_list)

for i in range(2 ** n):
    my_switch = gen_switch(i, n)
    for j in range(m):
        my_sum = 0
        for k in range(len(my_switch)):
            my_sum = my_sum + (my_switch[k] * my_mtx[j][k])
        if my_sum % 2 != my_list[j]:
            break
        if j == m - 1:
            count = count + 1

print(count)


### FIXED CODE ###

number = int(input())
my_set = set()
for i in range(number):
    input_line = input()
    splitted_line = input_line.split(" ")
    my_set.add((splitted_line[0], - int(splitted_line[1]), i+1))

my_sorted = sorted(my_set)

for item in my_sorted:
    print(item[2])
a,b = map(int,raw_input.split())
if(a>9 or b >9):
  print("-1")
else:
  print(a*b)
  

### FIXED CODE ###

x,y = map(int,input().split())
if(x<1 or x>9 or y<1 or y>9):
  print("-1")
else:
  print(x*y)
N, A, B, C, D = list(map(int, input().split()))

S = input()

# 以下indexに変更
A-=1
B-=1
C-=1
D-=1

L = [1]*N

# 0を岩、1を通路とする
for i in range(N):
    if S[i] == '#':
        L[i] =  0


def search(idx, g, reversed_goal):
    L[idx] =0
    if not reversed_goal:
        if idx+1 == g:
            L[idx] = 1
            L[g] = 0
            return True
        if idx+2 == g: 
            L[idx] = 1
            L[g] = 0
            return True

    else:
        if idx+2 == g and L[idx+1] and L[idx+3]:
            L[g] = 0
            return True

        if idx+1 == g and L[idx+2]:
            L[g] = 0
            return True

        if idx+1 == g or idx+2 == g:
            return False


    if reversed_goal and L[idx+2] and L[idx+1]:
        L[idx] =1
        L[idx+1] = 0
        return True


    if idx+2 <= g and L[idx+2]:
        L[idx] = 1
        return search(idx+2, g, reversed_goal)
    
    if idx+1 <= g and L[idx+1]:
        L[idx] = 1
        return search(idx+1, g, reversed_goal)
    
    return False

def main():
    reversed_goal = C > D
    if not reversed_goal:
        if search(B,D,False):
            if search(A,C,False):
                return 'Yes'
            
        return 'No'

    else:
        if search(B,D,True):
            if search(A,C,False):
                return 'Yes'

        return 'No'

ans = main()
print(ans)

### FIXED CODE ###

if __name__ == '__main__':
    N, A, B, C, D = map(int, input().split())
    S = str(input())
 
    answer = "-1"
 
    if C < D:
       if S[A:D:].count("##") >= 1:
           answer = "No"
       else:
           answer = "Yes"
    else:
       if S[B-2:D+1:].count("...") >= 1:
           answer = "Yes"
       else:
           answer = "No"
 
    print(answer)
#4
N = int(input())
x,y,k = 0,0

x = int(0.8*N)

for i in range(x,N):
    k = int(i*108)
    if k[0:-2] == N:
        print(i)
        y +=1
        break

if y !=1:
    print(":(")


### FIXED CODE ###

#4
import sys
N = int(input())
x,y,k = 0,0,0

if N == 1:
    print(1)
    sys.exit()
elif N <= 12:
    print(N)
    sys.exit()
x = int(0.8*N)

for i in range(x,N):
    k = str(i*108)
    if int(k[0:-2]) == N:
        print(i)
        y +=1
        break

if y !=1:
    print(":(")
N, M = [int(_) for _ in input().split()]
Brokens = [int(input()) for i in range(M)]
isBroken = [False] * (N + 1)
for i in Brokens:
    isBroken[i] = True


def solve():

    # It's impossible
    temp = Brokens[0]
    for a in Brokens[1:]:
        if a - 1 == temp:
            return "0"
        temp = a

    # We can
    memo = [0] * (N + 1)

    def rec(i):
        if i == 0:
            return 1
        if i < 0:
            return 0
        if isBroken[i]:
            return 0
        if memo[i] == 0:
            count1 = rec(i - 1)
            count2 = rec(i - 2)
            memo[i] = (count1 + count2) % 1000000007
            # print(f"memo[{i}] = {count1} + {count2} -> {memo[i]}")
        return memo[i]
    return rec(N)


print(solve())


### FIXED CODE ###

import sys
sys.setrecursionlimit(10 ** 7)

N, M = [int(_) for _ in input().split()]
A = [int(input()) for i in range(M)]
isBroken = [False] * (N + 1)
for i in A:
    isBroken[i] = True


def solve():

    # It's impossible
    if M >= 1:
        temp = A[0]
        for a in A[1:]:
            if a - 1 == temp:
                return 0
            temp = a

    # We can
    memo = [0] * (N + 2)

    def rec(i):
        if i == 0:
            return 1
        if i < 0:
            return 0
        if isBroken[i]:
            return 0

        if memo[i] == 0:
            count1 = rec(i - 1) % 1000000007
            count2 = rec(i - 2) % 1000000007
            memo[i] = (count1 + count2) % 1000000007
        return memo[i]
    return rec(N)


print(solve())
from itertools import count, takewhile
from math import floor, sqrt

n = int(input())
xys = [map(int, input().split()) for _ in range(n)]

def mysqrt(n):
    x = floor(sqrt(n))
    for y in takewhile(lambda y: y**2 <= n, count(x-1)):
        x = y
    return x

for x, y in xys:
    xy = x*y
    root = mysqrt(xy-1)
    ans = root*2 - (root**2 + root >= xy) - 1 + (x == y)
    print(ans)

### FIXED CODE ###

print('Yes' if set(input()) == set('abc') else 'No')
if len(str(n)) == 6:
    print(90909)
elif len(str(n)) == 4:
    print(909)
elif len(str(n)) == 2:
    print(9)
elif len(str(n)) == 1:
    print(n)
elif len(str(n)) == 3:
    print(9 + (n - 100) + 1)
elif len(str(n)) == 5:
    print(9 + 900 + (n - 10000) + 1)


### FIXED CODE ###

n = int(input())

if len(str(n)) == 6:
    print(90909)
elif len(str(n)) == 4:
    print(909)
elif len(str(n)) == 2:
    print(9)
elif len(str(n)) == 1:
    print(n)
elif len(str(n)) == 3:
    print(9 + (n - 100) + 1)
elif len(str(n)) == 5:
    print(9 + 900 + (n - 10000) + 1)
ans = []

for i in range(M-N+1):

    num = 0

    substring = input_list[0][i:i+N]

    for j in range(len(substring)):

        if substring[j] != input_list[1][j]:

            num += 1

    ans.append(num)

print(min(ans))


### FIXED CODE ###

input_list = [input() for i in range(2)]
M = input_list[0]
N = input_list[1]

ans = []

for i in range(len(M)-len(N)+1):

    num = 0

    substring = input_list[0][i:i+len(N)]

    for j in range(len(N)):

        if substring[j] != N[j]:

            num += 1

    ans.append(num)

print(min(ans))
N=int(input())
li = list(map(int,input().split()))

for i in li:
  if i%2 ==0:
    if i%3 == 0 or i%5 == 0:
    else:
      print('DENIED')
      break

print('APPROVED')

### FIXED CODE ###

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

flag = 0

for i in li:
  if i%2 ==0:
    if i%3 != 0 and i%5 != 0:
      print('DENIED')
      flag = 1
      break
    else:
      continue
      
if flag == 0:
  print('APPROVED')
N = int(input())

count = 0

for i in range(N+1):
  l, r = map(int, input().split())
  count += l-r+1
  
print(count)
  

### FIXED CODE ###

N = int(input())
a=[list(map(int,input().split())) for i in range(N)]
count = 0

for i in range(N):
  count += a[i][1] - a[i][0] + 1
  
print(count)
n = int(input())
x=[]
y=[]
h=[]
for i in range(0,n):
    a,b,c = map(int,input().split())
    x.append(a)
    y.append(b)
    h.append(c)
size = 101


for i in range(0,size):
    for j in range(0,size):
        tmph=0
        flag = True
        for k in range(0,n):
            if tmph == 0 and h[k] != 0:
                tmph=abs(x[k]-i)+abs(y[k]-j)+h[k]
            break
        for k in range(0,n):
            calch = abs(x[k]-i)+abs(y[k]-j)+h[k]
            if tmph != calch and h[k] != 0:
                flag = False
                break
            calcrh = tmph- abs(x[k]-i)-abs(y[k]-j)
            if calcrh != h[k]:
                flag = False
                break
        if flag == False:
            continue
        elif tmph == 0:
            flag2 = True
            for c in range(0,n):
                if i == x[c] and j == y[c]:
                    flag2 = False
                    break
            if flag2:
                ansx = i
                ansy = j
                ansh = 1
        else:
            ansx=i
            ansy=j
            ansh=tmph

print(ansx,ansy,ansh)


        


### FIXED CODE ###

n = int(input())
x=[]
y=[]
h=[]
for i in range(0,n):
    a,b,c = map(int,input().split())
    x.append(a)
    y.append(b)
    h.append(c)
 
 
 
for i in range(0,101):
    for j in range(0,101):
        tmph=0
        flag = True
        for k in range(0,n):
            if tmph == 0 and h[k] != 0:
                tmph=abs(x[k]-i)+abs(y[k]-j)+h[k]
                break
        for k in range(0,n):
            calch = tmph - abs(x[k]-i)-abs(y[k]-j)
            if h[k] != max(calch,0):
                flag = False
                break
        if flag == False:
            continue
        elif tmph == 0:
            flag2 = True
            for c in range(0,101):
                if i == x[c] and j == y[c]:
                    flag2 = False
                    break
            if flag2:
                ansx = i
                ansy = j
                ansh = 1
        else:
            ansx=i
            ansy=j
            ansh=tmph
 
print(ansx,ansy,ansh)
a = input()
b = input()
c = input()


def comp(x, y):
    return (x == '?') or (y == '?') or (x == y)


def check(s, t):
    check_st = {i: True for i in range(-5000, 5001)}
    for i in range(len(s)):
        for j in range(len(t)):
            if not comp(s[i], t[j]):
                check_st[i - j] = False
    return check_st


ans = len(a) + len(b) + len(c)
check_ab = check(a, b)
check_bc = check(b, c)
check_ca = check(c, a)
# print(check_ab)
# print(check_bc)
# print(check_ca)

for b_idx in range(-len(b) - len(c), len(a) + len(c) + 1):
    for c_idx in range(-len(b) - len(c), len(a) + len(b) + 1):
        if check_ab[b_idx] and check_ca[c_idx] and check_bc[b_idx - c_idx]:
            l_idx = min(0, b_idx, c_idx)
            r_idx = max(len(a), b_idx + len(b), c_idx + len(c))
            ans = min(ans, r_idx - l_idx)

print(ans)


### FIXED CODE ###

a = input()
b = input()
c = input()

OFFSETS = 9000


def comp(x, y):
    return (x == '?') or (y == '?') or (x == y)


def check(s, t):
    check_st = [True] * (OFFSETS * 2 + 10)
    for i, si in enumerate(s):
        for j, tj in enumerate(t):
            if not comp(si, tj):
                check_st[i - j + OFFSETS] = False
    return check_st


ans = len(a) + len(b) + len(c)
check_ab = check(a, b)
check_bc = check(b, c)
check_ac = check(a, c)
# print(check_ab)
# print(check_bc)
# print(check_ca)

for b_idx in range(-len(b) - len(c), len(a) + len(c) + 1):
    for c_idx in range(-len(b) - len(c), len(a) + len(b) + 1):
        if check_ab[b_idx + OFFSETS] and check_ac[
                c_idx + OFFSETS] and check_bc[c_idx - b_idx + OFFSETS]:
            l_idx = min(0, b_idx, c_idx)
            r_idx = max(len(a), b_idx + len(b), c_idx + len(c))
            ans = min(ans, r_idx - l_idx)

print(ans)
def s(x,v,d):
  r=[d,v]
  for u in g[v]:
    if u!=x:
      t=s(v,u,d+1)
      if r[0]<t[0]:r=t
  return r
n,*t=map(int,open(0).read().split())
g=[set()for _ in range(n+1)]
for a,b in zip(t[::2],t[1::2]):
  g[a].add(b)
  g[b].add(a)
print('SFeicrosntd'[s(0,s(0,1,0)[1],0)[0]%3!=1::2])

### FIXED CODE ###

import sys
sys.setrecursionlimit(250000)
def s(x,v,d):
  r=[d,v]
  for u in g[v]:
    if u!=x:
      t=s(v,u,d+1)
      if r[0]<t[0]:r=t
  return r
n,*t=map(int,open(0).read().split())
g=[[]for _ in range(n+1)]
for a,b in zip(t[::2],t[1::2]):
  g[a].append(b)
  g[b].append(a)
print('SFeicrosntd'[s(0,s(0,1,0)[1],0)[0]%3!=1::2])
x,y = map(int,input().split())
min = 2019
n = y-x
i=0
while(i<n):
  s = (x + i) % 2019
  i = i +1
  if s == 0:
    print(s)
    break
  elif min > s:
    min = s:
min2 = 2019
j=0
while(j<n):
  g = (x + j) % 2019
  j=j+1
  if g == 0:
    break
  elif min2 > g and g == s:
    min2 =g

if s != 0:
  z = (min*min2)%2019
  print(z)


### FIXED CODE ###

l, r = map(int, input().split())

min = 2019

for i in range(l, r+1):
    for j in range(i+1, r+1):
        p = (i % 2019)*(j % 2019) % 2019
        if p < min:
            min = p

        if min == 0:
            print("0")
            exit()

print(min)
#LCMを求めれば良い
a, b = map(int, input().split())

import math

c = math.gcd(a, b)
ans = a * b//c
print(ans)

### FIXED CODE ###

#LCMを求めれば良い
a, b = map(int, input().split())
s, t = max(a, b), min(a, b)
c = s%t
while (c != 0):
    s = t
    t = c
    c = s%t

ans = a * b//t
print(ans)
import sys
input = sys.stdin.readline

h, w, k = map(int, input().split())
s = []
for i in range(h):
    tmp = list(map(int, input()))
    s.append(tmp)

ans = h + w - 2
for i in range(2**(h-1)):
    l = []
    tmp = s[0]
    for j in range(h-1):
        if i >> j & 1:
            tmp = [tmp[m] + s[j+1][m] for m in range(w)]
        else:
            l.append(tmp)
            tmp = s[j+1]
    l.append(tmp)
    c = [0] * len(l)
    cnt = 0
    flag = False
    j = 0
    while j < w:
        for m in range(len(l)):
            c[m] += l[m][j]
            if c[m] > k:
                flag = True
        if flag:
            c = [0] * len(l)
            cnt += 1
            flag = False
            j -= 1
        j += 1
    ans = min(ans, len(l) + cnt - 1)

print(ans)

### FIXED CODE ###

H, W, K = map(int, input().split())
S = [list(input()) for _ in range(H)]

res = float('inf')
for i in range(2**(H-1)):
    c = bin(i).count('1')
    cnt = c
    sum_l = [0] * (c+1)
    j = 0
    flag = True
    while j < W:
        tmp = sum_l.copy()
        pos = 0
        for k in range(H):
            if S[k][j] == '1':
                tmp[pos] += 1
            if (i >> k) & 1:
                pos += 1
        if max(tmp) <= K:
            sum_l = tmp.copy()
            j += 1
            flag = False
        else:
            if flag:
                cnt = float('inf')
                break
            cnt += 1
            flag = True
            sum_l = [0] * (c+1)

    res = min(res, cnt)

print(res)
import sys
 
D = int(input())
if D == 22:
  output("Christmas Eve Eve Eve")
if D == 23:
  output("Christmas Eve Eve")
if D == 24:
  output("Christmas Eve")
if D == 25:
  output("Christmas")

### FIXED CODE ###

import sys
 
D = int(input())
if D == 22:
  print("Christmas Eve Eve Eve")
if D == 23:
  print("Christmas Eve Eve")
if D == 24:
  print("Christmas Eve")
if D == 25:
  print("Christmas")
import math
from functools import reduce

def gcd(*numbers):
    return reduce(math.gcd, numbers)
n = int(input())
A = sorted(list(map(int, input().split())))
print(gcd(*A))

### FIXED CODE ###

import fractions
n = int(input())
A = list(map(int, input().split()))
work = A[0]
for i in range(1, n):
    work = fractions.gcd(work, A[i])
print(work)
import numpy as np
h,w=map(int,input().split())
a=[list(input()) for i in range(h)]
np_a=np.array(a)
np_at=np_a.T
at=np_at.tolist()

r=[]
c=[]

for i in range(h):
    if a[i].count('#')==0:
        r.append(i)
for i in range(w):
    if at[i].count('#')==0:
        c.append(i)

k=h-len(r)
for i in r:
    del a[i]
for j in c:
    for i in range(k):
        del a[i][j]

for i in range(k):
    print(''.join(a[i]))

### FIXED CODE ###

import numpy as np
h,w=map(int,input().split())
a=[list(input()) for i in range(h)]
np_a=np.array(a)
np_at=np_a.T
at=np_at.tolist()

r=[]
c=[]

for i in range(h):
    if a[i].count('#')==0:
        r.append(i)
for i in range(w):
    if at[i].count('#')==0:
        c.append(i)

for i in range(len(r)):
    del a[r[i]-i]
for j in range(len(c)):
    for i in range(h-len(r)):
        del a[i][c[j]-j]

for i in range(h-len(r)):
    print(''.join(a[i]))
import copy
from math import gcd


# def gcd(a, b):
#     if b == 0:
#         return a
#     else:
#         return gcd(b, a%b)

def lcm(a, b):
    return (a // gcd(a, b)) * b

def main():
    n, m = map(int, input().split())
    # これだと72がREになる
    A = [int(x) for x in input().split()]
    # A_s = set(A)
    # A_ = copy.deepcopy(A)
    # a_lcm = A.pop()
    a_lcm = 1
    # Aの要素が複数ならlcmを計算する
    #if len(A) >= 1:
    for i in range(n):
        a_lcm = lcm(a_lcm, A[i])
    # mがlcmの半分よりも小さかったら0
    if (a_lcm / 2) > m:
    # if a_lcm > m * 2:
        print(0)
        exit()
    # for a in A:
    for i in range(n):
        # if a_lcm / 2 % A[i] == 0:
        if a_lcm // A[i] % 2 == 0: 
            print(0)
            exit()
    # # あとは定数倍の数調べて終わり
    ans = int((m - (a_lcm / 2)) // a_lcm) + 1
    print(ans)

if __name__ == '__main__':
    main()

### FIXED CODE ###

import copy
# from math import gcd


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

def lcm(a, b):
    return (a // gcd(a, b)) * b
def main():
    n, m = map(int, input().split())
    A = set([int(x) for x in input().split()])
    a_lcm = 1
    for a in A:
        a_lcm = lcm(a_lcm, a)
        # mがlcmの半分よりも小さかったら0
        if (a_lcm / 2) > m:
            print(0)
            exit()
    for a in A:
        if (a_lcm / 2) % a == 0:
            print(0)
            exit()
    # # あとは定数倍の数調べて終わり
    ans = int((m - (a_lcm / 2)) // a_lcm) + 1
    print(ans)

if __name__ == '__main__':
    main()
n, m, x = map(int, input().split())
A = [[] for _ in range(n)]
cost = [0] * n
for i in range(n):
  c_as = list(map(int, input().split()))
  cost[i], A[i] = c_as[0], c_as[1:]
INF = 10**9
ans = INF
for s in range(0, 1 << n):
  smart = [0] * m
  cost_sum = 0
  for i in range(n):
    if (s >> i) % 2 == 0:
      continue
    cost_sum += c[i]
    for j in range(m):
      smart[j] += A[i][j]
  ok = True
  for j in range(m):
    if smart[j] < x:
      ok = False
  if ok:
    ans = min(ans, cost_sum)
if ans == INF:
  ans = -1
print(ans)
    

### FIXED CODE ###

n, m, x = map(int, input().split())
A = [[] for _ in range(n)]
cost = [0] * n
for i in range(n):
  c_as = list(map(int, input().split()))
  cost[i], A[i] = c_as[0], c_as[1:]
INF = 10**9
ans = INF
for s in range(0, 1 << n):
  smart = [0] * m
  cost_sum = 0
  for i in range(n):
    if (s >> i) % 2 == 0:
      continue
    cost_sum += cost[i]
    for j in range(m):
      smart[j] += A[i][j]
  ok = True
  for j in range(m):
    if smart[j] < x:
      ok = False
  if ok:
    ans = min(ans, cost_sum)
if ans == INF:
  ans = -1
print(ans)
dat =list(input().split())

for i in dat:
	i = int(i)

dat.sort(reverse=True)

int asum = 0
int bsum = 0

for i in range(len(dat)):
         asum = asum + dat[i]
		
print(asum)

### FIXED CODE ###

n = int(input())
dat = list(input().split())

dat = list(map(int,dat))

dat.sort(reverse=True)

asum = 0
bsum = 0

for i in range(n):
	if i % 2 == 0:
		asum = asum + dat[i]
	else:
		bsum = bsum + dat[i]
		
print(asum-bsum)
n = int(input())
h = list(map(int, input().split()))
ans = 0
h = h[1:]
h1 = sorted(h, reverse=True)
ans = len(h[h.index(h1[0])+1:])
print(ans)

### FIXED CODE ###

n = int(input())
h = list(map(int, input().split()))
h = h[::-1]
ans = []
x = 0
if n > 1:
    for i in range(1,n):
        if h[i-1] <= h[i]:
            x += 1
        else:
            ans.append(x)
            x = 0
    ans.append(x)
else:
    ans.append(0)
print(max(ans))
n, k = map(int, input().split())

if k == 0:
	print(n**2)
	exit()
    
ans = 0
for b in range(k+1, n+1):
	p = n//b
	r = n%b
    
    ans += p*(b-k)-1
    ans += max(0, r-k+1)
print(ans)

### FIXED CODE ###

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

if k == 0:
    print(n**2)
    exit()
    
ans = 0
for b in range(k+1, n+1):
    ans_bk = (n-k)//b+1
    ans_b = ans_bk*(b-k)
    
    mod_k_max = ((n-k)//b)*b+k
    if n-mod_k_max+1 < b-k:
        ans_b -= ((b-k) - (n-mod_k_max+1))
    # print(ans_b)
    ans += ans_b
            
print(ans)
n = int(input())
vals = [*map(int, input().split())]
dp = [0] * n

dp[0] = 0 
dp[1] = abs(vals[0] - vals[1])

for i in range(2,n):
    dp[i] = min( dp[i-1] + abs(vals[i] - vals[i-1]), \
            dp[i-2] + abs(vals[i] - vals[i-2]))

print(dp[n-1])


### FIXED CODE ###

n = int(input())
vals = list(map(int, input().split()))
dp = [0] * n

dp[0] = 0 
dp[1] = abs(vals[0] - vals[1])

for i in range(2,n):
    dp[i] = min( dp[i-1] + abs(vals[i] - vals[i-1]), \
            dp[i-2] + abs(vals[i] - vals[i-2]))

print(dp[n-1])
S = input()
    Q = int(input())
    reverse = False
    front = ""
    end = S
     
    for i in range(Q):
        inp = input()
        if inp[0] == "1":
            reverse = ~reverse
        else:
            _, F, C = inp.split()
            if (F == "1") ^ reverse:
                front =front+C
            else:
                end = end+C
     
     
    if reverse:
        print(end[::-1]+front)
    else:
        print(front[::-1]+end)

### FIXED CODE ###

S = input()
Q = int(input())
reverse = False
front = ""
end = S

for _ in range(Q):
    I = input().split()
    if I[0] == "1":
        reverse = not reverse
    else:
        if (I[1] == "1") ^ reverse:
            front =front + I[2]
        else:
            end = end + I[2]


if reverse:
    print("".join(list(reversed(end)))+front)
else:
    print("".join(list(reversed(front)))+end)
i=0
while 1:
    x = raw_index()
    i++
    if x == 0:
        break()
    print 'Case %s: %s' % (i,x)

### FIXED CODE ###


i=0
while 1:
    x = raw_input()
    if x == "0":
        break
    i = i+1
    print "Case %s: %s" %(i,x)
n,a,b = map(int,input().split())
x=n//(a+b)
y=n - C1*(a+b)
if y >= a:
  y=a
print(a*x+y)

### FIXED CODE ###

n,a,b = map(int,input().split())
x=n//(a+b)
y=n - x*(a+b)
if y >= a:
  y=a
print(a*x+y)
num = raw_input().split(" ")

a = num[0]
b = num[1]
c = num[2]

if a<b and b<c:
    print("Yes")
else:
    print("No")




### FIXED CODE ###

num = raw_input().split(" ")

a = num[0]
b = num[1]
c = num[2]

if a<b and b<c:
    print("Yes")
else:
    print("No")