Problem:
 Score : 200 points    Problem Statement Given are 1 -digit positive integers a and b . Consider these two strings: the concatenation of b copies of the digit a , and the concatenation of a copies of the digit b . Which of these is lexicographically smaller?      Constraints  1 \leq a \leq 9  1 \leq b \leq 9  a and b are integers.         Input Input is given from Standard Input in the following format:  a  b       Output Print the lexicographically smaller of the two strings. (If the two strings are equal, print one of them.)        Sample Input 1 4 3      Sample Output 1 3333  We have two strings 444 and 3333 . Between them, 3333 is the lexicographically smaller.       Sample Input 2 7 7      Sample Output 2 7777777

Solution (Python):
a,b = map(int,input().split())
print(str(min(a,b))*max(a,b))

Solution (Python):
a, b = map(int, input().split())
print (str(a)*b if a <= b else str(b)*a)

Solution (Python):
a, b = input().split()
x = a * int(b)
y = b * int(a)
print(sorted([x, y])[0])

Solution (Python):






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



if a >= b: print(str(b)*a)
else: print(str(a)*b)

Solution (Python):
a,b=input().split()

li=[a*int(b),b*int(a)]

li.sort()

print(li[0])

Solution (Python):
a_str, b_str = input().split()
strings = [a_str * int(b_str)] + [b_str * int(a_str)]
strings.sort()
print(strings[0])

Solution (Python):
a,b = map(int, input().split())
if a > b:
    print(str(b)*a)
else:
    print(str(a)*b)

Solution (Python):

a, b = map(int, input().split())
f = str(a) * b
s = str(b) * a
print(min(f, s))

Solution (Python):
a, b = tuple(int(i) for i in input().split(' '))

if b > a:
    print(str(a) * b)
else:
    print(str(b) * a)

Solution (Python):
a, b = sorted(map(int, input().split()))
print(str(a)*b)

Solution (Python):



a, b = input().split()

str_a = a * int(b)
str_b = b * int(a)


if str_a>=str_b:
    print(str_b)
else:
    print(str_a)

Solution (Python):
a,b=input().split()
if int(a)<=int(b):
    print(a*int(b))
else:
    print(b*int(a))

Solution (Python):
a, b = map(int, input().split())
ans = min(str(a) * b, str(b) * a)
print(ans)

Solution (Python):

import sys


def solve(a: int, b: int):
    return str(a) * b if a < b else str(b) * a



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    a = int(next(tokens))  
    b = int(next(tokens))  
    print(solve(a, b))

if __name__ == '__main__':
    main()

Solution (Python):
a,b=map(str,input().split())

if a>=b:
  print(b*int(a))
elif b>=a:
  print(a*int(b))

Solution (Python):
A,B = map(str,input().split())
AB = A * int(B)
BA = B * int(A)

if A <= B:
    print(AB)
elif A > B:
    print(BA)

Solution (Python):
A,B = map(str,input().split())
AB = A * int(B)
BA = B * int(A)

if A < B:
    print(AB)
elif A > B:
    print(BA)
else:
    print(AB)

Solution (Python):
a,b=list(map(int,input().split()))
if str(a)*b >= str(b)*a:
    print(str(b)*a)
else:
    print(str(a)*b)

Solution (Python):
a, b = map(int, input().split())
ans = min(str(a) * b, str(b) * a)
print(ans)

Solution (Python):
import sys
input = sys.stdin.readline

a, b = map(int, input().split())
ans = str(a) * b if a <= b else str(b) * a
print(ans)

Solution (Python):
def compare(a, b):
    a_str = ''
    b_str = ''
    for _ in range(a):
        a_str += str(b)
    for _ in range(b):
        b_str += str(a)

    if int(a_str) > int(b_str):
        return a_str
    else:
        return b_str

if __name__ == "__main__":
    a, b = map(int, input().split(' '))
    print(compare(a, b))

Solution (Python):
i = list(map(int, input().split()))
a = i[0]
b = i[1]

if a <= b:
    print(str(a)*b)
else:
    print(str(b)*a)

Solution (Python):
a,b = map(int,input().split())
ans = list()
ans.append(str(a)*b)
ans.append(str(b)*a)
print(min(ans))

Solution (Python):
a,b = map(str,input().split())

a_int = int(a)
b_int = int(b)

ans = []
sa = ''
sb = ''
for _ in range(b_int):
	sa += a
for _ in range(a_int):
	sb += b

ans.append(sa)
ans.append(sb)

ans.sort()

print(ans[0])

Solution (Python):
_, a, b = sorted(input())
print(a * int(b))

Solution (Python):
a, b = map(int, input().split())
if a == b:
    print(str(a)*a)
elif a > b:
    print(str(b)*a)
else:
    print(str(a)*b)

Solution (Python):
a, b = map(int, input().split())
lista = [a for i in range(b)]
listb = [b for i in range(a)]
a2 = ''.join(map(str,lista))
b2 = ''.join(map(str,listb))
list =sorted([a2, b2])
print(list[0])

Solution (Python):
a, b = map(int, input().split())
print(sorted([str(a) * b, str(b) * a])[0])

Solution (Python):
a,b=map(int,input().split())
print(str(min(a,b))*max(a,b))

Solution (Python):
a,b = map(int,input().split())
ans = []
for _ in range(max(a,b)):
    ans.append(str(min(a,b)))
print(''.join(ans))

Solution (Python):
a,b = map(int,input().split())
if a < b:
  a,b = b,a
print(str(b)*a)

Solution (Python):
a, b = map(int, input().split())
print(str(min(a, b)) * max(a, b))

Solution (Python):
n,m = list(map(int,input().split()))
 
if n > m:
  for i in range(n):
    print(str(m),end="")
else:
  for i in range(m):
    print(str(n),end="")

Solution (Python):
a,b=map(int,input().split())
print(min(str(a)*b,str(b)*a))

Solution (Python):
A,B = [int(x) for x in input().split()]
roop = A
ans = 0
if A < B:
    roop = B
    B = A
    
for i in range(roop):
    print(B, end ="")

Solution (Python):
import sys, re, os
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from fractions import gcd
def input(): return sys.stdin.readline().strip()
def STR(): return input()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def S_MAP(): return map(str, input().split())
def LIST(): return list(map(int, input().split()))
def S_LIST(): return list(map(str, input().split()))
sys.setrecursionlimit(10 ** 9)
inf = sys.maxsize
mod = 10 ** 9 + 7

a,b = MAP()
c = [str(a) * b, str(b) * a]
c.sort()
print(c[0])

Solution (Python):
a, b = (int(x) for x in input().split())

a_s = str(a) * b
b_s = str(b) * a

if a_s < b_s:
    print(a_s)
else:
    print(b_s)

Solution (Python):
a, b = list(map(int, input().split()))

if (a < b):
    print(str(a) * b)
else:
    print(str(b) * a)

Solution (Python):
import math
a, b = input().split()
P = a*int(b)
Q = b*int(a)
if int(a)<int(b):
  print(P)
else:
  print(Q)

Solution (Python):
from sys import stdin
a,b=map(int,input().split())

if a <= b:
    n=a
    m=b
else:
    n=b
    m=a

print(str(n)*m)

Solution (Python):
a, b = map(int, input().split())
l = min(a, b)
m = max(a, b)
ans = str(l) * m
print(ans)

Solution (Python):
N=list(map(int,input().split()))
print(str(min(N))*max(N))

Solution (Python):
a, b = map(int, input().split())
if a<=b:
    c = [a]*b
    print(''.join(map(str, c)))
else:
    c = [b]*a
    print(''.join(map(str, c)))

Solution (Python):
A,B=map(int,input().split())

if(A>=B):
    for i in range(A):
        print(B,end="")

else:
    for i in range(B):
        print(A,end="")

Solution (Python):
A,B=map(int,input().split())
a=str(A)
b=str(B)
for x in range(B-1):
    a+=str(A)
for y in range(A-1):
    b+=str(B)
if A>=B:
    print(b)
else:
    print(a)

Solution (Python):
a, b = map(int,input().split())
if a < b:
    ans = str(a) * b
else:
    ans = str(b) * a
print(ans)

Solution (Python):
a,b = map(int,input().split())

if a>b:
     print(''.join(['{}'.format(b) for i in range(a)]))
else:
     print(''.join(['{}'.format(a) for i in range(b)]))

Solution (Python):
a, b = map(int, input().split())
if a > b:
  a, b = b, a
print(str(a) * b)

Solution (Python):
m, n = map(int, input().split())
a = "".join([str(m)]*n)
b = "".join([str(n)]*m)

if a <= b:
  print(a)
else:
  print(b)

Solution (Python):
def solve():
    N, M = map(int, input().split())
    n = str(N)
    m = str(M)
    l = [n*M, m*N]
    l.sort()
    return l[0]

print(solve())

Solution (Python):
import sys
input = sys.stdin.readline

def main():
    a, b = map(int, input().split())
    if a <= b:
        print(str(a) * b)
    else:
        print(str(b) * a)


if __name__ == "__main__":
    main()

Solution (Python):
a,b=map(int,input().split())
print(min(str(a)*b,str(b)*a))

Solution (Python):
a,b = map(int,input().split())
print(min(str(a) * b, str(b) * a))

Solution (Python):
def resolve():
    a, b = map(int, input().split())
    if a <= b:
        print(str(a)*b)
    else:
        print(str(b)*a)
resolve()

Solution (Python):
a,b = map(int, input().split())
c = [str(a)*b, str(b)*a]
c.sort()
print(c[0])

Solution (Python):
a, b = input().split()

A = ""
B = ""
for i in range(int(b)):
    A += a

for k in range(int(a)):
    B += b

if A[0] < B[0]:
    print(A)
else:
    print(B)

Solution (Python):
a,b=map(int,input().split())
m,n=0,0

for i in range(b):
    m += 10**i

for i in range(a):
    n += 10**i

if a >= b:
    print(n*b)
else:
    print(m*a)

Solution (Python):
a, b = input().split()
A = int(a)
B = int(b)

S = []

S.append(a*B)
S.append(b*A)
S.sort()

print(S[0])

Solution (Python):
a, b = map(int,input().split())


if a < b:
    print(str(a) * b)
elif a > b:
    print(str(b) * a)
else:
    print(str(a) * b)

Solution (Python):
a,b = map(str, input().split())

x=a*int(b)
y=b*int(a)

keta=min(len(x),len(y))

if int(x[:keta]) > int(y[:keta]):
    print(y)
elif int(x[:keta]) < int(y[:keta]):
    print(x)
else:
    print(x)

Solution (Python):
a, b = map(int, input().split())
lower = min(a, b)
upper = max(a, b)
for i in range(upper):
    print(lower, end="")
print()

Solution (Python):
a ,b= map(int,input().split())


if a > b:
    ans = [str(b)]*a
    ans = "".join(ans)
else:
    ans = [str(a)]*b
    ans = "".join(ans)
print(ans)

Solution (Python):
a, b = map(int, input().split())

fi = str(a)*b
se = str(b)*a

num = max(a, b)

for i in range(num):
    ff = int(fi[i])
    ss = int(se[i])
    if ff<ss:
        print(fi)
        break
    elif ss<ff:
        print(se)
        break
    else:
        pass

    if i==num-1:
        print(fi)

Solution (Python):








"""

"""
a,b=map(int,input().split())
m=str(a)*b
n=str(b)*a
if  m<n:
    print(m)
else:
    print(n)

Solution (Python):
i_a, i_b = map(str, input().split())

a = i_a * int(i_b)
b = i_b * int(i_a)

l = sorted([a, b])

print(l[0])

Solution (Python):
a, b = input().split()

ans=sorted([a*int(b), b*int(a)])
print(ans[0])

Solution (Python):
a, b = map(int, input().split())
if a < b:
    print(str(a)*b)
else:
    print(str(b)*a)

Solution (Python):
n,m=map(int,input().split())
nn=''
mm=''
for i in range(m):
  nn=nn+str(n)
for i in range(n):
  mm=mm+str(m)
mm=int(mm)
nn=int(nn)
if nn>mm:
  print(nn)
else:
  print(mm)

Solution (Python):
a,b = map(int,input().split())

ab = ""
ba = ""
for i in range(b):
    ab += str(a)
for i in range(a):
    ba += str(b)
l = [ab, ba]
l.sort()
print(l[0])

Solution (Python):
a,b = input().split()
A = int(a * int(b))
B = int(b * int(a))

if A >= B:
    print(str(A))
else:
    print(str(B))

Solution (Python):
a,b = list(input().split())

x = a*int(b)
y = b*int(a)

p = sorted([x,y])
print(p[0])

Solution (Python):
a,b = map(int,input().split())

ab = 0
ba = 0

for i in range(b):
    ab += a * (10 ** i)
for i in range(a):
    ba += b * (10 ** i)

ans = ab

if a > b:
    ans = ba
if a == b and ab > ba:
    ans = ba

print(ans)

Solution (Python):
a, b = map(int, input().split())
c = str(min(a, b))
print(c*(max(a, b)))

Solution (Python):
a,b = input().split()
if a<=b:
  print(a*int(b))
else:
  print(b*int(a))

Solution (Python):
a,b = map(int,input().split())
c = min(a,b)
d = max(a,b)
str1 = str(c)
for i in range(d-1):
    str1 = str1 + str(c)
print(str1)

Solution (Python):
a, b = map(int, input().split())
print(str(a) * b if a < b else str(b) * a)

Solution (Python):
a,b=map(int,input().split())
c=""
if a>=b:
    for i in range(a):
        c+=str(b)
else:
    for j in range(b):
        c+=str(a)
print(c)

Solution (Python):
a, b = input().split()

a_copy = int(a)
b_copy = int(b)

a = a * b_copy
b = b * a_copy

ans = sorted([a, b])[0]

print(ans)

Solution (Python):
ab = list(input().split())

ab.sort()
txt = ab[0] * int(ab[1])
print(txt)

Solution (Python):
a, b = map(str, input().split())
print(min(a*int(b), b*int(a)))

Solution (Python):
a, b = map(int, input().split())
if a > b:
	b = str(b)
	print(b * a)
else:
	a = str(a)
	print(a * b)

Solution (Python):
a, b = map(str, input().split())
print(min(a*int(b), b*int(a)))

Solution (Python):
a,b = input().split()

if a == b:
    print(a*int(b))

else:
    l=[]
    l.append(a*int(b))
    l.append(b*int(a))
    l.sort()
    print(l[0])

Solution (Python):
a, b=map(int, input().split())
if a < b:
    print(str(a)*b)
else:
    print(str(b)*a)

Solution (Python):
a,b=map(int,input().split())
if a < b:
    print(str(a)*b)
else:
    print(str(b)*a)

Solution (Python):
a,b=raw_input().split()
A = int(a * int(b))
B = int(b * int(a))
if A>=B:
    print(A)
else:
    print(B)

Solution (Python):
A,B = map(int,input().split())

ansA = ""
ansB = ""
for countA in range(B):
    ansA = ansA + str(A)
for countB in range(A):
    ansB = ansB + str(B)

list = [str(ansA),str(ansB)]
list.sort()

print(list[0])

Solution (Python):
a, b = map(int, input().split())
if a<b:
  print(str(a)*b)
else:
  print(str(b)*a)

Solution (Python):
a, b = map(int, input().split())
AB = int(str(a) * b)
BA = int(str(b) * a)
if AB <= BA:
    print(BA)
else:
    print(AB)

Solution (Python):
a, b = map(int, input().split())

a_con = str(a) * b
b_con = str(b) * a

l = [a_con, b_con]
l.sort()

print(l[0])

Solution (Python):
lis = list(map(int,input().split()))
lis = sorted(lis)
output = ''
for _ in range(lis[1]):
  output += str(lis[0])
print(output)

Solution (Python):
a, b = map(str, input().split())

tmp = [int(a) * b, a * int(b)]
tmp.sort()

print(tmp[0])

Solution (Python):
import sys
import math
a,b= map(int,input().split())

if a<b:
  print(str(a)*b)
else:
  print(str(b)*a)

Solution (Python):
a, b = map(int, input().split())

if a < b:
  ans = str(a) * b
else:
  ans = str(b) * a
  
print(ans)

Solution (Python):
a,b= input().split()
x=int(a*int(b))
y=int(b*int(a))

if x>y:print(x)
else:print(y)

Solution (Python):
a,b=input().split()
if int(a)>=int(b):
  print(int(a)*b)
else:
  print(int(b)*a)

Solution (Python):
a,b=map(int,input().split())
print(str(min(a,b))*max(a,b))

Solution (Python):
a,b= input().split()
x=int(a*int(b))
y=int(b*int(a))

if x>y:print(x)
else:print(y)

Solution (Python):
a, b = input().split()

print(sorted([a * int(b), b * int(a)])[0])

Solution (Python):
a, b = map(int, input().split())
if a > b:
    print(str(b) * a)
else:
    print(str(a) * b)

Solution (Python):

"""
Created on Tue Mar  3 23:58:11 2020

@author: Kanaru Sato
"""

a,b = input().split()

A = a*int(b)
B = b*int(a)

list = [A,B]
list.sort()

print(list[0])

Solution (Python):
a,b = map(int,input().split())
s = [a,b]
s.sort()
print(str(s[0])*s[1])

Solution (Python):
a,b=sorted(input().split());print(a*int(b))

Solution (Python):
a, b = list(map(str, input().split()))

an = a * int(b)
bn = b * int(a)
print(an if an <= bn else bn)

Solution (Python):
def main():
    a,b = list(map(int,input().split()))

    if(a >= b):
        print(str(b)*a)
    else:
        print(str(a)*b)

if __name__ == "__main__":
    main()

Solution (Python):
a,b=map(int,input().split())
print( str(a)*b if str(a)*b < str(b)*a else str(b)*a)

Solution (Python):
a, b= map(int, input().split())

if a > b:
  ans = [str(b)] * a
else:
  ans = [str(a)] * b
  
print(''.join(ans))

Solution (Python):
a, b = input().split()
list1 = [a * int(b), b * int(a)]
L = sorted(list1)
print(L[0])

Solution (Python):
a,b = [int(i) for i in input().split(" ")]
ans = []
ans.append(str(a)*b)
ans.append(str(b)*a)
ans = sorted(ans)
print(ans[0])

Solution (Python):
a, b = map(int, input().split())
ans = str(a) * b if a < b else str(b) * a
print(ans)

Solution (Python):
a, b = sorted(input().split())
print(a * int(b))

Solution (Python):
N,M=map(int,input().split())
ans=str(N)*M
if N>M:
  ans=str(M)*N
print(ans)

Solution (Python):
a,b = map(int, input().split())
aa = str(a)
bb = str(b)
ab = aa*b
ba = bb*a
if ab<ba:
  print(ab)
else:
  print(ba)

Solution (Python):
a, b = map(int, input().split())

if a <= b:
    print(str(a) * b)
else:
    print(str(b) * a)

Solution (Python):
a,b = map(int,input().split())
if str(a)*b<str(b)*a:
    print(str(a)*b)
else:
    print(str(b)*a)

Solution (Python):
a,b = map(int,input().split())

a2 = int(str(a)*b)
b2 = int(str(b)*a)

print(max(a2,b2))

Solution (Python):
a, b = input().split()

l = [a * int(b), b * int(a)]

print(sorted(l)[0])

Solution (Python):
a, b = map(int, input().split())
print(sorted([str(a) * b, str(b) * a])[0])

Solution (Python):
input_numbers = list(map(int,input().split()))
a = input_numbers[0]
b = input_numbers[1]
A = a
B = b
x = 0
y = 0
while A > 0:
  x += 10 ** (A-1) * b
  A -= 1
while B > 0:
  y += 10 ** (B-1) * a
  B -= 1
if x > y:
  print(x)
else:
  print(y)

Solution (Python):
a,b = map(int,input().split())
ans = 0
if a >= b:
    ans = str(b)*a
else:
    ans = str(a)*b

print(ans)

Solution (Python):
a, b = map(int, input().split())
l = []

l.append(str(a)*b)
l.append(str(b)*a)

l_new = sorted(l)
print(l_new[0])

Solution (Python):
a, b = map(int, input().split())
tmp1, tmp2 = '', ''
for _ in range(b):
    tmp1 += str(a)
for _ in range(a):
    tmp2 += str(b)

tmp3 = [tmp1, tmp2]
tmp3.sort()
print(tmp3[0])

Solution (Python):
a,b = input().split()
if int(a) <= int(b):
  print(str(a)*int(b))
else:
  print(str(b)*int(a))

Solution (Python):
a, b = map(int, input().split(' '))

aa = str(a) * b
bb = str(b) * a

print(min(aa, bb))

Solution (Python):
a, b = map(int, input().split())
if a >= b:
    for i in range(a):
        print(b, end="")
else:
    for i in range(b):
        print(a, end="")

Solution (Python):
a,b = map(int, input().split())

if a < b:
  print(str(a) * b)
else:
  print(str(b) * a)

Solution (Python):
a = list(map(int,input().split()))
a = sorted(a)
num = []
for i in range(a[1]):
  num.append(a[0])
  num = list(map(str,num))
num = "".join(num)
print(num)

Solution (Python):
a,b = map(int,input().split())
if a<b:
  min = a
  max = b
else:
  min = b
  max = a
c =[min for i in range(max)]
d = map(str,c)
l = "".join(d)
print(l)

Solution (Python):
a,b = map(int,input().split())
if a<=b:
    print(str(a)*b)
else:
    print(str(b)*a)

Solution (Python):
a, b = map(int, input().split())
aa = [min(a, b)] * max(a, b)
print("".join(map(str, aa)))

Solution (Python):



import numpy as np



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

stra = str(a)*b
strb = str(b)*a

ans = min(stra,strb)

print(ans)

Solution (Python):
a,b = map(int,input().split())
print(str(min(a,b))*max(a,b))

Solution (Python):
Ns = list(map(int,input().split()))  

L=[]
for i in range(max(Ns)):
    L.append(min(Ns))
result = ''.join([str(n) for n in L])
print(int(result))

Solution (Python):
a,b=map(int, input().split())
x=str(a)*b
y=str(b)*a
print(min(x,y))

Solution (Python):
a, b = map(int, input().split())
if a == b:
  for i in range(a):
    print("{}".format(b), end="")
elif a > b:
  for i in range(a):
    print("{}".format(b), end="")
else:
  for i in range(b):
    print("{}".format(a), end="")

Solution (Python):
a,b = map(str,input().split())
print(min(a*int(b),b*int(a)))

Solution (Python):
a,b=map(int,input().split())

if int((str(a)*b)[0])>=int((str(b)*a)[0]):
    print(str(b)*a)
else:
    print(str(a)*b)

Solution (Python):
a, b = input().split()

A = a * int(b)
B = b * int(a)

list = [A,B]

list.sort()
print(list[0])

Solution (Python):
a, b = map(int,input().split())
if a > b:
    print(str(b) * a)
elif a <= b:
    print(str(a) * b)

Solution (Python):
a, b = map(int,input().split())
if a<=b:
  ans = str(a)*b
else:
  ans = str(b)*a
  
print(ans)

Solution (Python):
a,b=sorted(list(map(int,input().split())))
print(a*(10**b-1)//9)

Solution (Python):
a, b = map(int, input().split())
if a>=b:
  ans = str(b) * a 
else:
  ans = str(a) * b

print(ans)

Solution (Python):
a, b = map(int, input().split(' '))
if a < b:
    print(str(a)*b)
else:
    print(str(b)*a)

Solution (Python):
import sys
sys.setrecursionlimit(12345678)
import itertools
from collections import Counter
from collections import defaultdict
from collections import deque
import bisect
from heapq import heappush, heappop


def main():
    a, b = map(int, input().split())
    if a > b:
        print(str(b) * a)
    else:
        print(str(a) * b)


if __name__ == '__main__':
    main()

Solution (Python):
import sys
input = sys.stdin.readline
MOD = 10**9 + 7
INF = float('INF')

def main():
    a, b = list(map(int,input().split()))
    if a > b:
        a, b = b, a

    print(str(a)*b)

if __name__ == '__main__':
    main()

Solution (Python):
a, b = input().split()

A = a * int(b)
B = b * int(a)

if A <= B:
    print(A)
else:
    print(B)

Solution (Python):
a, b = input().split()

print(min(a * int(b), b * int(a)))

Solution (Python):
a, b = [ i for i in input().split(" ") ]

str1 = a * int(b)
str2 = b * int(a)

print( min(str1, str2))

Solution (Python):
a, b = map(int, input().split())
if(a < b):
    print(str(a)*b)
else:
    print(str(b)*a)

Solution (Python):
a,b = map(int,input().split())
print(sorted([str(a)*b,str(b)*a])[0])

Solution (Python):
a,b=map(int,input().split())
ans=""
if a<=b:
    ans+=str(a)*b
else:
    ans+=str(b)*a
print(ans)

Solution (Python):
a, b = map(int, input().split())

ans = ['', '']
for i in range(b):
    ans[0] += str(a)

b_ans = ''
for i in range(a):
    ans[1] += str(b)

ans.sort()
print(ans[0])

Solution (Python):
import sys


def solve():
    readline = sys.stdin.buffer.readline
    mod = 10 ** 9 + 7
    a, b = list(map(str, readline().rstrip().decode('utf-8').split()))
    if a * int(b) < b * int(a):
        print(a * int(b))
    else:
        print(b * int(a))


if __name__ == '__main__':
    solve()

Solution (Python):
import sys
sys.setrecursionlimit(10 ** 7)
read = sys.stdin.buffer.read 
input = sys.stdin.buffer.readline
def inputS(): return input().rstrip().decode()
readlines = sys.stdin.buffer.readlines 

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

ans = sorted([str(A)*B, str(B)*A])
print(ans[0])

Solution (Python):
def main():
    a,b = map(int, input().split())

    array = []
    array.append(str(a)*b)
    array.append(str(b)*a)
    array = sorted(array)
    print(array[0])


if __name__ == '__main__':
    main()

Solution (Python):
a,b = map(int, input().split())

aa = ""
bb = ""

for i in range(b):
    aa =  aa + str(a)

for i in range(a):
    bb = bb + str(b)

aaa = int(aa)
bbb = int(bb)

if aaa <= bbb:
    print(bbb)
else:
    print(aaa)

Solution (Python):
a,b = map(int, input().split())

aa = str(a)*b

bb = str(b)*a

print(min(aa,bb))

Solution (Python):
lista=[]
a,b=(int(x) for x in input().split())
lista=[str(a)*b,a*str(b)]
lista=sorted(lista)

print(lista[0])

Solution (Python):
a,b = map(int,input().split())

ab =[]
ba = []

for i in range(b):
  ab.append(str(a))
  
for i in range(a):
  ba.append(str(b))

ab.sort()
ba.sort()

if ab < ba:
  print("".join(ab))
else: 
  print("".join(ba))

Solution (Python):
a,b = map(int, input().split())
print(str(a)*b if a<=b else str(b)*a)

Solution (Python):
a,b=map(int,input().split())
aa=str(a)*b
bb=str(b)*a
print(aa) if aa<=bb else print(bb)

Solution (Python):
a,b = map(int,input().split())
c = str(a)
d = str(b)
if a >= b:
  print(d*a)
else:
  print(c*b)

Solution (Python):
a, b = map(int, input().split())


if int(a) < int(b):
    A = ''
    for _ in range(b):
        A += str(a)
    print(A)
else:
    B = ''
    for _ in range(a):
        B += str(b)
    print(B)

Solution (Python):
a,b = map(int,input().split())
if a>b:
    print(str(b)*a)
else:
    print(str(a)*b)

Solution (Python):
a, b = map(int, input().split())
if str(a)*b > str(b)*a:
    print(str(b)*a)
else:
    print(str(a)*b)

Solution (Python):
n,k = map(int,input().split())
l = ["",""]
for i in range(n):
    l[1] = l[1] + str(k)
for i in range(k):
    l[0] = l[0] + str(n)
l.sort()
print(l[0])

Solution (Python):

if __name__ == '__main__':
    a, b = [int(x) for x in input().split(' ')]
    if a < b:
        a, b = b, a
    print(str(b) * a)

Solution (Python):
a, b = map(int, input().split())
x = []
y = []
for i in range(a):
    x.append(str(b))
for i in range(b):
    y.append(str(a))
x = "".join(x)
y = "".join(y)
dic = [x, y]
dic.sort()
print(dic[0])

Solution (Python):
a, b = list(map(int, input().split(' ')))
print_val = min(a,b)
count_val = max(a,b)
S = ''
for i in range(count_val):
    S += str(print_val)
print(S)

Solution (Python):
a, b = input().split()

S = [a * int(b), b * int(a)]
S.sort()

print(S[0])

Solution (Python):
a,b = map(int,input().split())
s = 0
if a <= b:
    for i in range(0,b):
        s += a*(10**i)

else:
    for i in range(0,a):
        s += b*(10**i)

print(s)

Solution (Python):
a,b = map(int,input().split())
print(min(str(a)*b, str(b)*a))

Solution (Python):
a,b=input().split()
print(min(a*int(b),b*int(a)))

Solution (Python):
a,b=input().split()
print(a*int(b) if a<b else b*int(a))

Solution (Python):
a, b = input().split()
if a < b:
    print(a * int(b))
else:
    print(b * int(a))

Solution (Python):






import math





MOD = 10**9 +7
INF = float('inf')





kaijo_memo = []
def kaijo(n):
  if(len(kaijo_memo) > n):
    return kaijo_memo[n]
  if(len(kaijo_memo) == 0):
    kaijo_memo.append(1)
  while(len(kaijo_memo) <= n):
    kaijo_memo.append(kaijo_memo[-1] * len(kaijo_memo) % MOD)
  return kaijo_memo[n]

gyaku_kaijo_memo = []
def gyaku_kaijo(n):
  if(len(gyaku_kaijo_memo) > n):
    return gyaku_kaijo_memo[n]
  if(len(gyaku_kaijo_memo) == 0):
    gyaku_kaijo_memo.append(1)
  while(len(gyaku_kaijo_memo) <= n):
    gyaku_kaijo_memo.append(gyaku_kaijo_memo[-1] * pow(len(gyaku_kaijo_memo),MOD-2,MOD) % MOD)
  return gyaku_kaijo_memo[n]

def nCr(n,r):
  if(n == r):
    return 1
  if(n < r or r < 0):
    return 0
  ret = 1
  ret = ret * kaijo(n) % MOD
  ret = ret * gyaku_kaijo(r) % MOD
  ret = ret * gyaku_kaijo(n-r) % MOD
  return ret





a,b = map(int, input().split())
 
if a >= b:
  print(str(b)*a)
else:
  print(str(a)*b)

Solution (Python):
a,b = map(int,input().split())
result = ''
if a > b:
  for i in range(a):
    result+=str(b)
elif a <= b:
  for i in range(b):
    result+=str(a)
print(result)

Solution (Python):
a, b = map(int, input().split())
if a <= b:
  print(str(a)*b)
else:
  print(str(b)*a)

Solution (Python):
a,b =map(int, input().split())
if a > b:
    print(str(b)*a)
else:
    print(str(a)*b)

Solution (Python):
a, b = map(int, input().split())
aStr = str()
bStr = str()

for i in range(b):
    aStr = aStr + str(a)

for i in range(a):
    bStr = bStr + str(b)

if aStr > bStr:
    print(bStr)
else:
    print(aStr)

Solution (Python):
a = list(map(str, input().split()))
 
if a[0] <= a[1]:
    print(a[0] * int(a[1]))
else:
    print(a[1] * int(a[0]))

Solution (Python):
A,B=map(int,input().split())
if A<B:
	for i in range (B):
		print(A,end="")
	print()
else:
	for i in range (A):
		print(B,end="")
	print()

Solution (Python):
a,b=map(int,input().split())
x=0
if a>b:
    temp=a
    a=b
    b=temp
for i in range(b):
    x+=(10**i)*a
print(x)

Solution (Python):
a, b = input().split()
ans = []
if a <= b:
  ans = [a for i in range(int(b))]
  print(''.join(ans))
else:
  ans = [b for i in range(int(a))]
  print(''.join(ans))

Solution (Python):
M, N = map(int, input().split())

if M > N:
  body = N
  numm = M
else:
  body = M
  numm = N

ret = ''
for i in range(numm):
  ret += str(body)
print(ret)

Solution (Python):
a,b=input().split()
c=[0]*2
c[0],c[1]=a*int(b),b*int(a)
c.sort()
print(c[0])

Solution (Python):
import sys

sys.setrecursionlimit(1000000)
input = lambda: sys.stdin.readline().rstrip()

a, b = map(int, input().split())
if a < b:
    print(str(a) * b)
else:
    print(str(b) * a)

Solution (Python):



from math import *
from copy import *
from string import *				
from random import *				
from sys import stdin
from sys import maxsize
from operator import *				
from itertools import *
from collections import Counter		
from collections import defaultdict 

'''

'''

def solve(l):
	n = len(l)
	

a,b = list(map(int, stdin.readline().rstrip().split()))
aa = str(a)*b
ab = str(b)*a
print(min(aa,ab))

Solution (Python):
ab = input().split(' ')
print(min(ab[0]*int(ab[1]), ab[1]*int(ab[0])))

Solution (Python):
a, b = list(map(int, input().split()))
print(str(a)*b if a < b else str(b)*a)

Solution (Python):
a, b = map(int, input().split())

print(min([str(a)*b, str(b)*a]))

Solution (Python):
a, b = [int(n) for n in input().split()]
sa = str(a)*b
sb = str(b)*a
print(min(sa, sb))

Solution (Python):
data = list(input().split(' '))
a = data[0]
b = data[1]
if a <= b :
  s = str(a) * int(b)
else :
  s = str(b) * int(a)
print(s)

Solution (Python):
a,b = map(int,input().split())
if a < b:
    print(str(a)*b)
else:
    print(str(b)*a)

Solution (Python):
import sys

input = sys.stdin.readline

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

if a <= b:
    print(int(str(a) * b))
elif b < a:
    print(int(str(b) * a))

Solution (Python):
n,m=map(int,input().split())
a=str(n)*m
b=str(m)*n
arr=sorted([a,b])
print(arr[0])

Solution (Python):
a,b = map(int,input().split())

A=str(a)*int(b)
B=str(b)*int(a)
ans=sorted([A,B])

print(ans[0])

Solution (Python):
a,b=input().split()

if int(a)<int(b):
    print(a*int(b))
elif int(a)>=int(b):
    print(b*int(a))

Solution (Python):
a,b = map(int,input().split())

if a < b:
  print(str(a)*b)
elif a > b:
  print(str(b)*a)
else:
  print(str(a)*b)

Solution (Python):
a, b = map(int, input().split())

a_b = ""
b_a = ""

for i in range(a):
    b_a = str(b_a) + str(b)  

for ii in range(b):
    a_b = str(a_b) + str(a)
    
if a==b:
    print(a_b)
elif a>b:
    print(b_a)
else:
    print(a_b)

Solution (Python):
import numpy as np

num = np.array(list(map(int, input().split())))
num_1 = 0

if num[0] > num[1]:
  for i in range(0,num[0]) :
    num_1 = num_1 + num[1]*(10**i)
else:
  for i in range(0,num[1]) :
    num_1 = num_1 + num[0]*(10**i)
    
print(num_1)

Solution (Python):
a,b = map(int,input().split())

a1 = ''
b1 = ''

for i in range(b):
    a1 = a1 + str(a)
for i in range(a):
    b1 = b1 + str(b)

if a1 < b1:
    print(a1)
else:
    print(b1)

Solution (Python):
a, b = map(int, input().split())
if a > b :
  print(str(b) * a)
else :
  print(str(a) * b)

Solution (Python):
a, b = input().split()

l = sorted([a * int(b), b * int(a)])

print(l[0])

Solution (Python):
a, b = map(int, input().split())
x, y = 0, 0
for i in range(b):
    x += a * (10 ** i)
for i in range(a):
    y += b * (10 ** i)
if a <= b:
    print(x)
else:
    print(y)

Solution (Python):
a,b = map(int,input().split())
print(str(min(a,b))*max(a,b))

Solution (Python):
x=input().split()
a=int(x[0])
b=int(x[1])
res=''
c=min(a,b)
d=max(a,b)
for k in range(d):
  res+=str(c)
print(res)

Solution (Python):
a,b=map(int,input().split())
l=[str(a)*b,str(b)*a]
l=sorted(l)
print(l[0])

Solution (Python):
a, b =map(int, input().split())

for i in range(max(a, b)):
    print(min(a, b), end="")

Solution (Python):
a, b = map(int, input().split())

if a <= b:
    print(str(a) * b)
else:
    print(str(b) * a)

Solution (Python):
a, b = map(int,input().split())
if a >= b:
  print(str(b)*a)
else:
  print(str(a)*b)

Solution (Python):
a,b=map(int,input().split())
if a>=b:
    print(str(b)*a)
else:
    print(str(a)*b)

Solution (Python):
a,b = sorted(input().split())
print(a*int(b))

Solution (Python):
a,b =input().split()

if a<b:
    print(a*int(b))
else:
    print(b*int(a))