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=list(map(int,input().split()))
A.sort()
if A[0]==A[1]:
    print(A[0]*str(A[1]))
else:
    print(A[1]*str(A[0]))

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

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

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())
c = 0
if a<=b:
  for i in range(b):
    c += a*(10**i)
  print(c)
else:
  for i in range(a):
    c += b*(10**i)
  print(c)

Solution (Python):

a, b = [s for s in input().split()]

axb = a * int(b)
bxa = b * int(a)

print(min(axb, bxa))

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(str(a)*b if a <= b else str(b)*a)

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

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

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

Solution (Python):
import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,random,time,copy,functools
from collections import deque

sys.setrecursionlimit(10**7)
inf = 10**20
mod = 10**9 + 7

DR = [1, -1, 0, 0]
DC = [0, 0, 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 LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def I(): return int(sys.stdin.readline())
def F(): return float(sys.stdin.readline())
def S(): return input()
     
a, b = LI()
print(min(str(a)*b, str(b) * a))

Solution (Python):
a,b=list(map(int,input().split()))
mx=max(a,b)
mn=min(a,b)
mns=(str(mn))
s=mns*mx
print(s)

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

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

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

print(aa if aa < b else bb)

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

Solution (Python):
import sys
input = sys.stdin.readline
rs = lambda: input().strip()
ri = lambda: int(input())
rl = lambda: list(map(int, input().split()))
mod = 10**9 + 7

a, b = rl()

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

Solution (Python):

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

def connection(one, two):
  character = " "
  one_str = str(one)
  for i in range(two):
    character = one_str + character 
  return character

aa = connection(a, b)
bb = connection(b, a)

ans = sorted([aa, bb])

print(ans[0])

Solution (Python):


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

a_str = str(a)
b_str = str(b)

aa = " "
bb = " "

for i in range(b):
  aa = a_str + aa

for j in range(a):
  bb = b_str + bb

dummy = [aa, bb]
ans = sorted(dummy)

print(ans[0])

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

c=[a,b]
c=sorted(c)
print(c[0])

Solution (Python):
from collections import deque, Counter as cnt
from collections import defaultdict as dd
from operator import itemgetter as ig
from bisect import bisect_right as bsr
from math import factorial, ceil, floor
import sys
sys.setrecursionlimit(1000000)


args = None
INF = float("inf")
MOD = int(1e9 + 7)


def input(*ps):
    if type(ps[0]) is list:
        return [input(*ps[0][:-1]) for _ in range(ps[0][-1])]
    elif len(ps) == 1:
        return ps[0](next(args))
    else:
        return [p(next(args)) for p in ps]


def nlist(n, v):
    if not n:
        return [] if type(v) is list else v
    return [nlist(n[1:], v) for _ in range(n[0])]


def yesno(v, yes="Yes", no="No", upper=False):
    if upper:
        print([yes.upper(), no.upper()][not v])
    else:
        print([yes, no][not v])


def main():
    """エントリーポイント"""
    A, B = input(str, str)
    print(sorted([A * int(B), B * int(A)])[0])


if __name__ == '__main__':
    args = iter(sys.stdin.read().split())
    main()

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

Solution (Python):
a, b = input().split()
ls = []
ls.append(a*int(b))
ls.append(b*int(a))
ls.sort()
print(ls[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 = input().split();
num_a = int(a);
num_b = int(b);

if num_b >= num_a:
  print(a*num_b);
else:
  print(b*num_a);

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

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

a = str(min(n))
b = max(n)

print(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 = input().split()
print(a*int(b) if a<b else b*int(a))

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

Solution (Python):


def main():
    a, b = map(int, open(0).read().split())
    R = []
    if (a < b):
        for i in range(b):
            R.append(str(a))
    else:
        for i in range(a):
            R.append(str(b))
    print(''.join(R))


main()

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

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

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

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

Solution (Python):
a,b = input().split(" ")
s1 = a * int(b)
s2 = b * int(a)

print(min(s1,s2))

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

sa=''
for i in range(int(b)):
  sa=sa+a


sb=''
for i in range(int(a)):
  sb=sb+b


print(sa if sa<sb else sb)

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

for i in range(max(a,b)):
  ans+=str(min(a,b))

print(int(ans))

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 = (int(x) for x in input().split())
p = [str(a)]*b
P = "".join(p)
q = [str(b)]*a
Q = "".join(q)
words = [P, Q]
word = sorted(words)[0]
print(word)

Solution (Python):
def main():
    a, b = input().split()
    ia = a*int(b)
    ib = b*int(a)
    if ia > ib:
        print(int(ib))
    elif ia < ib:
        print(int(ia))
    else:
        print(int(ia))
main()

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

Solution (Python):
def small(x,y):
  if x>y:
    return str(y)*x
  else:
    return str(x)*y
  
a,b=map(int,input().split())
result=small(a,b)
print(result)

Solution (Python):
from itertools import repeat
a,b = map(int, input().split())
if b < a:
  a, b = b, a
print(''.join(repeat(str(a), b)))

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

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

Solution (Python):
a,b=input().split()
s1=""
for i in range(int(b)):
    s1=s1+a
s2=""
for j in range(int(a)):
    s2=s2+b
l=sorted([s1,s2])
print(l[0])

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

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

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

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

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

c.sort()

print(c[0])

Solution (Python):
a, b = (int(x) for x in input().split())
a1 = str(a)*b
b1 = str(b)*a
lis = [a1, b1]
new_lis = sorted(lis)
print(new_lis[0])

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

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

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

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

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

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

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

Solution (Python):
a, b = input().split()
if int(a[0]) < int(b[0]):
    print(a * int(b))
else:
    print(b * int(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=map(int,input().split())

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

Solution (Python):

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

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

if a<b:
  print(a2)
else:
  print(b2)

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())


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

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

Solution (Python):
def q2():
    a, b = (int(i) for i in input().split())
    if a >= b:
        print(str(b)*a)
    else:
        print(str(a)*b)


if __name__ == '__main__':
    q2()

Solution (Python):
'''
INPUT SHORTCUTS
N, K = map(int,input().split())
N ,A,B = map(int,input().split())
string = str(input())
arr = list(map(int,input().split()))
N = int(input())
'''


a, b = map(int,input().split())
res = ''
if a<=b:
	for _ in range(b):
		res += str(a)
else:
	for _ in range(a):
		res += str(b)
print(res)

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

Solution (Python):



a, b= [int(i) for i in 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())
S1 = str(a) * b
S2 = str(b) * a

if a < b:
    print(S1)
else:
    print(S2)

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

s1 = "".join([str(a)] * b)
s2 = "".join([str(b)] * a)

print(min(s1, s2))

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

if n >= m:
    print(str(m) * n)
else:
    print(str(n) * m)

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

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

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

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

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

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

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

Solution (Python):
a, b = map(int, input().split())
'''
s = str(b)*a
t = str(a)*b
if s >= t:
    print(t)
else:
    print(s)
'''
for i in range(max(a,b)):
    print(min(a,b),end="")

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

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

Solution (Python):
a,b=map(int,input().split())
s=''
t=''
for i in range(a):
  s+=str(b)
for j in range(b):
  t+=str(a)
print(min(s,t))

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

if n > m:
    print(str(m) * n)
else:
    print(str(n) * m)

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

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

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

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



if aa*b <= bb*a:
    print(aa*b)
else:
    print(bb*a)

Solution (Python):
x = input()
a = int(x.split()[0])
b = int(x.split()[1])
sum_a = ''
sum_b = ''

for i in range(b):
    str_a = str(a)
    sum_a = sum_a + str_a
sum_a = int(sum_a)

for i in range(a):
    str_b = str(b)
    sum_b = sum_b + str_b
sum_b = int(sum_b)

if sum_a >= sum_b:
    print(sum_a)
else:
    print(sum_b)

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

l = ['{}'.format(a)*b, '{}'.format(b)*a]
l.sort()
print(l[0])

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

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

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

A = a * int(b)
B = b * int(a)
print(min(A, B))

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

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

if __name__ == "__main__":
    main()

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(int(str(a)*b) if a<b else int(str(b)*a))

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


if __name__ == '__main__':
    main()

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

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

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




print(str(min(a,b))*max(a,b))

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

Solution (Python):

import sys


def solve(a: int, b: int):
    if a>b:
        print("".join(str(b)*a))
    else:
        print("".join(str(a)*b))
    return



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))  
    solve(a, b)

if __name__ == '__main__':
    main()

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 = sorted([str(a)*b,str(b)*a])

print(ans[0])

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

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

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

Solution (Python):
A,B = [int(v) for v in input().split()]

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

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

Solution (Python):


def main():
     a, b = map(int, input().split())
     if a <= b:
          word = ''.join([str(a) for i in range(b)])
     else:
          word = ''.join([str(b) for i in range(a)])

     print(word)

if __name__ == "__main__":
    main()

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

ans=' '
if a >= b:
    for i in range(int(a)):
        ans += b
else:
    for i in range(int(b)):
        ans += a
print(ans)

Solution (Python):
import sys


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


if __name__ == '__main__':
    solve()

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):
import math

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

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

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

Solution (Python):
a,b = map(int,input().split())
dum1 = min(a,b)
dum2 = max(a,b)
ans = ""
for i in range(dum2):
  ans += str(dum1)
print(ans)

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

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

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

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

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

if a==b: 
	print(A)

elif a>b:
	print(B)
else:
	print(A)

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

s1 = a * int(b)
s2 = b * int(a)

print(s1 if s1 < s2 else s2)

Solution (Python):
a, b = (int(x) for x in input().split())
result = ""
if a > b:
    for _ in range(a):
        result += str(b)
else:
    for _ in range(b):
        result += str(a)
print(result)

Solution (Python):
import sys
x = list(map(int,input().split()))

a = x[0]
b = x[1]

if a > b:
    large = a
    small = b
elif a < b:
    large = b
    small = a
else:
    ans = ''.join([str(a)]*a)
    print(ans)
    sys.exit()

ans = ''.join([str(small)]*large)
print(ans)

Solution (Python):
n, m = map(int,input().strip().split())
temp = int('{}'.format(n)*m)
m = int('{}'.format(m)*n)
temp = str(temp)
m = str(m)
if temp==m:
    print(temp)
elif temp[0]<m[0]:
    print(temp)
else:
    print(m)

Solution (Python):
a,b=map(int, input().split())
ans = ""
for i in range(max([a,b])):
  ans = ans + str(min([a,b]))
print(ans)

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

print(min(x,y))

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

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

Solution (Python):
def main():
    import sys
    input = sys.stdin.readline
    sys.setrecursionlimit(10**7)
    from collections import Counter, deque
    
    from itertools import combinations, permutations, accumulate, groupby
    
    from bisect import bisect_left,bisect_right
    from heapq import heapify, heappop, heappush
    from math import floor, ceil
    

    
    

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

if __name__ == '__main__':
    main()

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

x = a * bint
y = b * aint
print(x if x <= y else y)

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

print(str(x)*y)

Solution (Python):
a,b = map(int,input().split())
if a < b:
        print("{}".format(a)*b)
else:
        print("{}".format(b)*a)

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

if a < b:
    for i in range(b):
        print(a, end = "")
else:
    for i in range(a):
        print(b, end = "")

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


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


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

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

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())
s = ''
if a < b:
    for i in range(b):
        s += str(a)
else:
    for i in range(a):
        s += str(b)
print(s)

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

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()

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

print(min(A, B))

Solution (Python):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

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

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

A = 0
B = 0

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

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

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

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

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

one=str(a)*b
two=str(b)*a

print(min(one,two))

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

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

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

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

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

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

print(str(min(a, b))*max(a, b))

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

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

Solution (Python):
base = input().split()
a = int(base[0])
b = int(base[1])
if a>b:
    for i in range(a):
        print(b,end = "")
elif 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())
print('{}'.format(a)*b if a <= b else '{}'.format(b)*a)

Solution (Python):

def input1():
	return int(input())


def input2():
	return map(int,input().split())


def input_array():
	return list(map(int,input().split()))


a,b=input2()


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

print(min(str_a,str_b))

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 = input().split()

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

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

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

Solution (Python):
import os

def main():
	num_strings = ""
	a,b = map(int, input().split())
	if a <= b:
		for i in range(b):
			num_strings += str(a) 
	else:
		for i in range(a):
			num_strings += str(b)
	
	print(num_strings)

if __name__ == '__main__':
	main()

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())
for i in range(max(a, b)):
    print((min(a, b)), end='')
print()

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):
a, b = map(int, input().split())

a1 = 0
for i in range(b):
  a1 = a1*10 + a
  
b1 = 0
for i in range(a):
  b1 = b1*10 + b
  
print(max(a1,b1))

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())
print(str(a)*b if a<=b else str(b)*a)

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

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

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

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

Solution (Python):
import io
import math

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

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):
n, m = map(int, input().split())
if n > m:
    print(str(m)*n)
else:
    print(str(n)*m)

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())

astr = str(a) * b
bstr = str(b) * a

if astr < bstr:
  print(astr)
else:
  print(bstr)

Solution (Python):

ab = input().split(' ')
a = int(ab[0]) ; b = int(ab[1])
if a < b:
    print(str(a) * b)
else:
    print(str(b) * a)

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

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

Ans=[]
Ans.append(A)
Ans.append(B)

Ans.sort()

print(Ans[0])

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

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

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

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

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

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

if M>N:
    print(str(N)*M)
else:
    print(str(M)*N)

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 str(a)*b <= str(b)*a else str(b)*a)

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


string = ""
if a > b:
  b = str(b)
  for i in range(a):
    string += b
else:
  a = str(a)
  for i in range(b):
    string += a
print(string)

Solution (Python):
str=list(input().split())
cal=[int(s) for s in str]

str[0]+=str[0]*(cal[1]-1)
str[1]+=str[1]*(cal[0]-1)

str.sort()
print(str[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())
x = []
if a >= b:
    for i in range(a):
        x.append(b)
else:
    for i in range(b):
        x.append(a)

print("".join(map(str, x)))

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

Solution (Python):
inputted = input().split()
a = inputted[0]
b = inputted[1]

ab = a * int(b)
ba = b * int(a)

answer = ab if a <= b else ba

print(answer)

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

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

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

lst = list()

lst.append(a * int(b))
lst.append(b * int(a))

print(sorted(lst)[0])

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

s = str(min(a,b)) * max(a, b);

print(s);

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

for i in range(max(A,B)):
    S.append(min(A,B))

print(*S,sep="")

Solution (Python):
a,b = map(int,input().split())
s_a = ''.join([str(a) for _ in range(b)])
s_b = ''.join([str(b) for _ in range(a)])
if a < b:
    print(s_a)
else:
    print(s_b)

Solution (Python):
import sys
import os

ii = lambda: int(sys.stdin.buffer.readline().rstrip())
il = lambda: list(map(int, sys.stdin.buffer.readline().split()))
fl = lambda: list(map(float, sys.stdin.buffer.readline().split()))
iln = lambda n: [int(sys.stdin.buffer.readline().rstrip()) for _ in range(n)]

iss = lambda: sys.stdin.buffer.readline().decode().rstrip()
sl = lambda: list(map(str, sys.stdin.buffer.readline().decode().split()))
isn = lambda n: [sys.stdin.buffer.readline().decode().rstrip() for _ in range(n)]


def main():
    if os.getenv("LOCAL"):
        sys.stdin = open("input.txt", "r")

    A, B = sl()
    AB = ''
    BA = ''
    for _ in range(int(B)):
        AB += A
    for _ in range(int(A)):
        BA += B
    print(AB if AB < BA else BA)


if __name__ == '__main__':
    main()

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

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

lis.sort()
slist = [lis[0] for i in range(int(lis[1]))]
print("".join(slist))

Solution (Python):
import sys

sr = lambda: sys.stdin.readline().rstrip()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

A, B = lr()
if B < A:
    A, B = B, A
answer = str(A) * B
print(answer)

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

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

Solution (Python):
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do():
    a,b=INTM()
    print(str(min(a,b))*max(a,b))
if __name__ == '__main__':
    do()

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

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

if a <= b:
    print('{}'.format(a)*b) 
else:
    print('{}'.format(b)*a)

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

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

if aa >= bb:
  print(str(aa))
else:
  print(str(bb))

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

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

S = A * b
T = B * a
s = int(S)
t = int(T)

if s<t:
    print(t)
if s>=t:
    print(s)

Solution (Python):
a=input().split();print(min(a)*int(max(a)))

Solution (Python):
x,y = map(int,input().split())

if x==y:
    print(str(x)*y)
else:
    print(str(min(x,y)) * max(x,y))

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

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

if int(a)<=int(b):
    print(x)
else:
    print(y)

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

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

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=map(int,input().split());print(str(min(A,B))*max(A,B))

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