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):
N, M=map(int,input().split())
if N == M:
  for x in range(0, N):
    print(N, end="")
elif N > M:
  for x in range(0, N):
    print(M, end="")
else:
  for x in range(0, M):
    print(N, end="")

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

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

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

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

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

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

print(str(max(int(A),int(B))))

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

str_a = [a] * b
str_b = [b] * a

if str_a > str_b:
    print(''.join(map(str, str_b)))
else:
    print(''.join(map(str, str_a)))

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

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

aa, bb = "", ""

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

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

if len(aa) <= len(bb):
    length = len(aa)
    ans = aa
else:
    length = len(bb)
    ans = bb

flag = 0
for i in range(length):
    if int(aa[i]) < int(bb[i]):
        flag = 1
        break
    elif int(aa[i]) > int(bb[i]):
        flag = -1
        break

if flag == 1:
    print(aa)
elif flag == -1:
    print(bb)
else:
    print(ans)

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

Solution (Python):
from sys import stdin
lines = stdin.readlines()
 
a, b = map(str, lines[0].split())

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

if A > B:
  print(B)
elif B > A:
  print(A)
elif B == A:
  print(A)

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

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

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

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

result = str_a
n = len(str_a)
for i in range(0,n):
  if int(str_a[i]) > int(str_b[i]):
    result = str_b
    break
  elif int(str_a[i]) < int(str_b[i]):
    result = str_a
    break
print(result)

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

Solution (Python):
input_list = list(map(int, input().split()))
num_f = input_list[0]
num_s = input_list[1]
f_str = str(num_f) * num_s
s_str = str(num_s) * num_f
list_ans = [f_str, s_str]
print(sorted(list_ans)[0])

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

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

Solution (Python):

a, b = map(int, input().split())
A = str(a)*b
B = str(b)*a
l = list([A, B])
l.sort()
print(l[0])

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

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

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

Solution (Python):
a, b = map(int, input().split())
c = str(a)
d = str(b)
f = str(a)
g = str(b)
for i in range(b-1):
	c += f
for o in range(a-1):
	d += g
e =[c, d]
e.sort()
print(e[0])

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

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

numa = str(a) * b
numb = str(b) * a

if b > a:
    print(numa)
else:
    print(numb)

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

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

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

if int(a2) >= int(b2):
  print(a2)
else:
  print(b2)

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

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

Solution (Python):
a, b = input().split()
s,t = "", ""
i, j = 0, 0
while(i<int(b)):
  s += a
  i += 1

while (j<int(a)):
  t += b
  j += 1

if (int(a)<int(b)):
  print(s)
elif(int(a) == int(b)):
  print(s)
else:
  print(t)

Solution (Python):
num=[int(e) for e in input().split()]
A=str(num[0])
B = str(num[1])

if num[0]>=num[1]:
  for i in range(num[0]-1):
    B+=str(num[1])
  print(B)
else:
  for i in range(num[1]-1):
      A+=str(num[0])
  print(A)

Solution (Python):
x = input().split()
n = x[0]
m = x[1]
print(min(n*int(m), m*int(n)))

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

ans = ''

if a <= b:
  for i in range(b):
    ans += str(a)
else: 
  for i in range(a):
    ans += str(b)  
 
print(ans)

Solution (Python):
L, R = map(int,input().split())
l = str(L)
r = str(R)
last_l = ""
last_r = ""
for i in range(L):
    last_r += r 
for i in range(R):
    last_l += l     
if L > R:
    print(last_r)
else:
    print(last_l)

Solution (Python):
N, M = (int(i) for i in input().split(' '))

if N * str(M) <= M * str(N):
  print(N*str(M))
else:
  print(M*str(N))

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

Solution (Python):
import math

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

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

Solution (Python):
a, b = input().split()
s,t = "", ""
i, j = 0, 0
while(i<int(b)):
  s += a
  i += 1

while (j<int(a)):
  t += b
  j += 1

if (int(a)<int(b)):
  print(s)
elif(int(a) == int(b)):
  print(s)
else:
  print(t)

Solution (Python):
a, b = [int(i) for i in input().split()]
A = str(a) * b
B = str(b) * a
print(A if int(A)>int(B) else B )

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

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

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

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

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

list = []
x = ''
for i in range(b):
  A = str(a)
  x = x + A
list.append(x)
  
y = ''
for i in range(a):
  B = str(b)
  y = y + B
list.append(y)

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

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


str_ = ''

if int(a) > int(b):
    for _ in range(int(a)):
        str_ = str_ + b    

elif int(a) <= int(b):
    for _ in range(int(b)):
        str_ = str_ + a

print(str_)

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

ans=None

if a>b:

    ans=str(b)*a   

else:

    ans=str(a)*b

print(ans)

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

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

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

    print(result)
elif a < b:
    for i in range(b):
        result += str(a)

    print(result)
elif a > b:
    for i in range(a):
        result += str(b)

    print(result)

Solution (Python):
ab = input().split(' ')
a = ''
if ord(ab[0]) > ord(ab[1]):
  for i in range(int(ab[0])):
    a += ab[1]
else:
  for i in range(int(ab[1])):
    a += ab[0]
    
print(str(a))

Solution (Python):
a,b = map(int, input().split())
minab = min(a,b)
maxab = max(a,b)
answer = ''
for x in range(maxab):
    answer = answer + str(minab)

print(answer)

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

if a > b:
    ans = ''
    for target_list in range(a):
        ans = ans + str(b)

    print(ans)

if b > a:
    ans = ''
    for target_list in range(b):
        ans = ans + str(a)

    print(ans)
    

if b == a:
    ans = ''
    for target_list in range(b):
        ans = ans + str(a)

    print(ans)

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

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

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

Solution (Python):
a, b = map(int, input().split(" "))
num =""
if a < b:
	
	for i in range(b):
		num += str(a)

else:
	
	for i in range(a):
		num += str(b)
print(num)

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

Solution (Python):

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

Solution (Python):
a,b=input().split()
num1=""
for i in range(int(b)):
    num1+=a
num2=""
for i in range(int(a)):
    num2+=b
print(min(num1,num2))

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

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

Solution (Python):
a, b = input().split()
aa = ""
bb = ""
for i in range(0, int(b)):
    aa += a
for j in range(0, int(a)):
    bb += b

if (int(a)>int(b)):
    print(bb)
else:
    print(aa)

Solution (Python):
import sys

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



if A > B:
    for i in range(A):
        sys.stdout.write(str(B))
    sys.stdout.write("\n")
else:
    for i in range(B):
        sys.stdout.write(str(A))
    sys.stdout.write("\n")

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

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


if a <= b:
    c = a
    for i in range(b-1):
        c = str(c) + str(a)
else:
    c = b
    for i in range(a-1):
        c = str(c) + str(b)
print(c)

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

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

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

p = str(a)
q = str(b)
ans = ""

if(a==b):
  for i in range(a):
    ans += p
elif(a>b):
  for i in range(a):
    ans += q
elif(a<b):
  for i in range(b):
    ans += p
print(ans)

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

s1 = str(a)*b
s2 = str(b)*a
print(sorted([s1,s2])[0])

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

ans_a = 0
ans_b = 0
ans = []
for i in range(b):
    ans_a = ans_a + a*10**i

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

ans_a = str(ans_a)
ans_b = str(ans_b)

ans = [ans_a,ans_b]
answer = sorted(ans)
c = answer[0]
print(answer[0])

Solution (Python):
def p_result(lenn, numm):
    result = ""
    for i in range(lenn):
        result += str(numm)
    print(result)


num = list(map(int, input().split()))
if 1 <= num[0] <= 9 and 1 <= num[1] <= 9:
    if num[0] >= num[1]:
        p_result(num[0], num[1])
    elif num[0] <= num[1]:
        p_result(num[1], num[0])
    else:
        p_result(num[0], num[1])

Solution (Python):
a,b = map(int, input().split())
aList = [b]*a
bList = [a]*b
i = 0
l = min(len(bList),len(aList))
if a==b:
    pass
else:
    while aList[i]==bList[i]:
        i+=1
        if i+1==l:
            break
if aList[i]>bList[i]:
    print(*bList,sep="")
else:
    print(*aList,sep="")

Solution (Python):
a,b=input().split()
x,y=int(a),int(b)
c,d=x*b,y*a
l=[]
l.append(c)
l.append(d)
l.sort()
print(l[0])

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

X = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
Y = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0]

for i in range(b):
    X[i] = str(a)
for j in range(a):
    Y[j] = str(b)

for k in range(9):
    if int(X[k]) < int(Y[k]):
        ｎX = [e for e in X if e != 0]
        print(''.join(nX))
        break
    elif int(X[k]) > int(Y[k]):
        ｎY = [e for e in Y if e != 0]
        print(''.join(nY))
        break
    else:
        if k == 8:
            ｎX = [e for e in X if e != 0]
            print(''.join(nX))

Solution (Python):
a,b = input().split()
a_int = int(a)
b_int = int(b)
ab = a*b_int
ba = b*a_int
if ab >= ba:
    print(ba)
elif ab <= ba:
    print(ab)

Solution (Python):

from collections import defaultdict,deque
from heapq import heappush, heappop
from bisect import bisect_left, bisect_right
import sys, random, itertools, math
sys.setrecursionlimit(10**5)
input = sys.stdin.readline
sqrt = math.sqrt
def LI(): return list(map(int, input().split()))
def LF(): return list(map(float, input().split()))
def LI_(): return list(map(lambda x: int(x)-1, input().split()))
def II(): return int(input())
def IF(): return float(input())
def LS(): return list(map(list, input().split()))
def S(): return list(input().rstrip())
def IR(n): return [II() for _ in range(n)]
def LIR(n): return [LI() for _ in range(n)]
def FR(n): return [IF() for _ in range(n)]
def LFR(n): return [LI() for _ in range(n)]
def LIR_(n): return [LI_() for _ in range(n)]
def SR(n): return [S() for _ in range(n)]
def LSR(n): return [LS() for _ in range(n)]
mod = 1000000007
inf = float('INF')


def solve():
    a, b = LI()
    ans = [str(a) * b, str(b) * a]
    ans.sort()
    print(ans[0])
    return



if __name__ == '__main__':
    solve()

Solution (Python):
a,b = map(int, input().split())
aList = [b]*a
bList = [a]*b
i = 0
l = min(len(bList),len(aList))
if a==b:
    pass
else:
    while aList[i]==bList[i]:
        i+=1
        if i+1==l:
            break
if aList[i]>bList[i]:
    print(*bList,sep="")
else:
    print(*aList,sep="")

Solution (Python):
a,b = (int(x) for x in input().split())
N = 0
M = 0
A = []
B = []
for i in range(0,b):
    N += a * (10 ** i)
    A.append(a)
for j in range(0,a):
    M += b * (10 ** j)
    B.append(b)
if A[0] <= B[0]:
    print(N)
else:
    print(M)

Solution (Python):
from fractions import gcd


import heapq
import math
from collections import defaultdict, Counter, deque
from bisect import *
import itertools
import fractions
import sys
sys.setrecursionlimit(10 ** 7)
MOD = 10 ** 9 + 7



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


def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)

    
    return divisors


def factorize(n):
    fct = []  
    b, e = 2, 0  
    while b * b <= n:
        while n % b == 0:
            n = n // b
            e = e + 1
        if e > 0:
            fct.append((b, e))
        b, e = b + 1, 0
    if n > 1:
        fct.append((n, 1))
    return fct


def is_prime(n):
    if n == 1:
        return False

    for k in range(2, int(math.sqrt(n)) + 1):
        if n % k == 0:
            return False

    return True


def primes(n):
    is_prime = [True] * (n + 1)
    is_prime[0] = False
    is_prime[1] = False
    for i in range(2, int(n**0.5) + 1):
        if not is_prime[i]:
            continue
        for j in range(i * 2, n + 1, i):
            is_prime[j] = False
    return [i for i in range(n + 1) if is_prime[i]]

def modpow(a, n, mod):
    res = 1
    while n > 0:
        if n & 1:
            res = res * a % mod
        a = a * a % mod
        n >>= 1
    return res


def modinv(a, mod):
    return modpow(a, mod - 2, mod)


def cnk(a, b):
    MOD = 10**9+7
    ret = 1
    for i in range(b):
        ret *= (a-i)
        ret %= MOD
        ret = ret * modinv(i+1, MOD) % MOD
    return ret




def main():
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    

            

    
    
    
    
    
    
    
    
    

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




    


if __name__ == '__main__':
    main()

Solution (Python):
a,b=(int(x) for x in input().split())
i = 0
if a > b:
  while i < a:
    print(str(b), end="")
    i += 1
else:
  while i < b:
    print(str(a), end="")
    i += 1

Solution (Python):

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

Solution (Python):
a,b = list(map(int,input().split()))
if a==b:
    print(str(a)*b)
elif 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:
    for _ in range(a):
        print(b, end="")

    print()

else:
    for _ in range(b):
        print(a, end="")

    print()

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

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

Solution (Python):
a, b = (int(i) for i in input().split())
str_a = str(a)*b
str_b = str(b)*a
list_a = [str_a, str_b]
lst = sorted(list_a)
print(lst[0])

Solution (Python):


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

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

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

Solution (Python):
import sys

result = input().split()

str1 = str(result[0])*int(result[1])
str2 = str(result[1])*int(result[0])

if str1 < str2:
    print(str1)
else:
    print(str2)

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

Solution (Python):
a,b=map(int,input().split())
if a>b:
   c=[]
   for i in range(a):
       c.append(str(b))
   d=''.join(c)
else:
    c = []
    for i in range(b):
        c.append(str(a))
    d = ''.join(c)
print(d)

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

new_a = str(a)
new_b = str(b)
ans_a = int(new_a * b)
ans_b = int(new_b * a)

if a >= b:
  print(ans_b)
else:
  print(ans_a)

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

ans = ""
bns = ""

for i in range(int(b)):
    ans += a
for j in range(int(a)):
    bns += b

if int(ans) > int(bns):
    print(int(ans))
else:
    print(int(bns))

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

if a > b:
    a, b = b, a

print(str(a) * b)

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

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

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

i = 1
A = a
while i < int(b):
    A = A + a
    i = i + 1

i = 1
B = b
while i < int(a):
    B = B + b
    i = i + 1




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

Solution (Python):
a,b=map(int,input().split())
A=str(a)*b
B=str(b)*a
for i in range(min(len(A),len(B))):
  if int(A[i])>int(B[i]):
    print(B)
    break
  elif int(A[i])<int(B[i]):
    print(A)
    break
  if i==min(len(A),len(B))-1:
    print(A)

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

for i in range(b):
    A = A + str(a)
for i in range(a):
    B = B + str(b)
L = [A,B]
l = sorted(L)
print(l[0])

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

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

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

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

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

for i in range(A-1):
    para_a = para_a + str(B)

for i in range(B-1):
    para_b = para_b + str(A)

if para_a < para_b:
    print(para_a)
else:
    print(para_b)

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

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

Solution (Python):
x,y=map(int,input().split())
c1=[]
c2=[]
for i in range(y):
    c1.append(x)
for i in range(x):
    c2.append(y) 
ans=[]       

for i in range(min(x,y)):
    if c1[i]<c2[i]:
        ans=c1
        break    
    elif c1[i]>c2[i]:
        ans=c2
        break

if ans==[]:
    if x<y:
        for i in range(len(c1)):
            print(c1[i],end="")    
    else:
          for i in range(len(c2)):
            print(c2[i],end="")  
else:
       for i in range(len(ans)):
            print(ans[i],end="")

Solution (Python):
a, b = map(int,input().split())
small = min(a, b)
st_small = str(small)
large = max(a, b)
count = 0
list = []
while count < large:
  list += st_small
  count += 1
print(''.join(list))

Solution (Python):
a, b = input().split()
ab = a * int(b)
ba = b * int(a)
i = 0
while i < len(ab) and i < len(ba):
    if ab[i] == ba[i]:
        i += 1
        continue
    elif int(ab[i]) < int(ba[i]):
        print(ab)
        break
    else:
        print(ba)
        break
if i == len(ab):
    print(ab)
elif i == len(ba):
    print(ba)

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

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


if ab>=ba:
    print(ba)
else:
    print(ab)

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

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

Solution (Python):
s=input().split()
a=int(s[0])
b=int(s[1])
out=[]
for i in range(max(a,b)):
    print(min(a,b),end='')
print()

Solution (Python):

import sys
from functools import reduce
from operator import add

def solve(a: int, b: int):
    if a <= b:
        a_str = str(a)
        for _ in range(b - 1):
            a_str += str(a)
        print(a_str)
    else:
        b_str = str(b)
        for _ in range(a - 1):
            b_str += str(b)
        print(b_str)

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

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

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

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


def main():
    a, b = input().split()
    print(min(a * int(b), b * int(a)))


if __name__ == "__main__":
    main()

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

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

Bb = 0
j = 0
for j in range (a):
    B = (10**j)*b
    Bb = B + Bb
    j=j+1
    
list = [Aa, Bb]
sorted = sorted(list)

print (sorted [1])

Solution (Python):
A,B = map(int, input().split())
P = max(A,B)
Q = min(A,B)
for i in range(int(P)):
  print(str(Q), end="")

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

if N>M:
    M = str(M)
    print("{}".format(M*N))
else:
    N = str(N)
    print("{}".format(N*M))

Solution (Python):
usr_input = input().split()
usr_input_1 = [usr_input[0]*int(usr_input[1]), usr_input[1]*int(usr_input[0])]
usr_input_1_sorted = sorted(usr_input_1, key = str)

print(usr_input_1_sorted[0])

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

ab = ""
ba = ""

for i in range(b):
  ab = ab + input_ab[0]

for i in range(a):
  ba = ba + input_ab[1]

dic = [ab, ba]
sdic = sorted(dic)

print(sdic[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())

x1=str(a)*int(b)
x2=str(b)*int(a)

if(a<b):
  print (x1)
  
elif(b<a):
  print (x2)
  
else:
  print (x1)

Solution (Python):
def make_num(a, b):
    num = ""
    for i in range(b):
        num += str(a)
    return num

def slove(a, b):

    num1 = make_num(a, b)
    num2 = make_num(b, a)
    
    return min(num1, num2)

if __name__ == "__main__":

    a, b = [int(i) for i in input().split()]
    ans = slove(a, b)
    print(ans)

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

c = max(a, b)
d = str(min(a, b))

print(d*c)

Solution (Python):
a,b=list(map(int,input().split()))
A=B=''
for i in range(b):
  A=A+str(a)
for i in range(a):
  B=B+str(b)

print((min(A,B)))

Solution (Python):
a, b = map(str, input().split())
a_arr, b_arr = [], []
a_str, b_str, = "", ""
for _ in range(int(a)):
  b_arr.append(b)
b_str = "".join(b_arr)
for _ in range(int(b)):
  a_arr.append(a)
a_str = "".join(a_arr)
if a_str > b_str:
  print(b_str)
elif b_str < a_str:
  print(a_str)
else:
  print(a_str)

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

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

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

tmp = [a_s,b_s]
ans = sorted(tmp)[0]

print(ans)

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

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

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

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

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

print(m if len(m) > len(n) else n )

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

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

for i in range(int(b)-1):
    ansa += a

for j in range(int(a)-1):
    ansb += b

if int(a) <= int(b):
    print(ansa)

else:
    print(ansb)

Solution (Python):
a, b = [int(i) for i in input().split()]
A = str(a) * b
B = str(b) * a
print(A if int(A)>int(B) else B )

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

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

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

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

print(aa if a < b else bb)

Solution (Python):
s = input().split()
result = ""

if s[1] >= s[0]:
    for i in range(int(s[1])):
        result += str(s[0])
    print(result)
else:
    for i in range(int(s[0])):
        result += str(s[1])
    print(result)

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

Solution (Python):
Input = input().split()
Input[0] = int(Input[0])
Input[1] = int(Input[1])
 
if Input[0] >= Input[1]:
  print(str(Input[1])*Input[0])
  
else:
  print(str(Input[0])*Input[1])

Solution (Python):
a, b = map(int, input().split())
A = []
B = []
for i in range(a):
    A.append(b)
A = map(str, A)
A = ''.join(A)
for i in range(b):
    B.append(a)
B = map(str, B)
B = ''.join(B)
if len(A)==len(B):
    print(A)
else:
    if A[0]<B[0]:
        print(A)
    else:
        print(B)

Solution (Python):


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

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

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

i=1
j=1

c=a
d=b

while(i<b):
  c+=a*(10**i)
  i+=1

while(j<a):
  d+=b*(10**j)
  j+=1

list=[str(c),str(d)]
list.sort()

if(a==b):
  print(str(c))
else:
  print(list[0])

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):
a,b=map(int,input().split())
c=[a]*b
d=[b]*a
for i in range(1):
  if c[i]>d[i]:
    e=str(b)*a
    print(e)
  elif c[i]==d[i]:
    if len(c)>len(d):
      z=str(a)*b
        
      print(z)
    else:
      s=str(b)*a
      print(s)
  else:
    g=str(a)*b
    print(g)

Solution (Python):


def main():
  A,B=map(int, input().split())
  num_max = max(A,B)
  num_min = min(A,B)
  res = ""
  for i in range(num_max):
    res = str(res) + str(num_min)
  print(res)


if __name__ == '__main__':
  main()

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

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

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

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

print(sorted([str1, str2])[0])

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

Solution (Python):
a,b=map(str,input().split())
ab=""
ba=""
for i in range(int(a)):
    ab+=b
for i in range(int(b)):
    ba+=a


if(ab>ba):
    print(int(ba))
elif(ab==ba):
    print(int(ab))
else:
    print(int(ab))

Solution (Python):


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

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

print(min(ab,ba))

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

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

Solution (Python):
a, b = map(int, input().split())
c = 0
d = 0
for i in range(b):
    c += (10 ** i) * a
for j in range(a):
    d += (10 ** j) * b
k = [str(c),str(d)]
k.sort()
print(k[0])

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

Solution (Python):
hoge = input().split(" ")
a=""
b=""
for i in range(int(hoge[1])):
  a += hoge[0]
for i in range(int(hoge[0])):
  b += hoge[1]
txt = [a,b]
txt.sort()
print(txt[0])

Solution (Python):
input_line = list(map(int,input().split()))
c = []
d = []
result_list = []

for i in range(input_line[1]):
    c.append(input_line[0])
    map_result = map(str, c)
    c_result = ''.join(map_result)

for i in range(input_line[0]):
    d.append(input_line[1])
    map_result = map(str, d)
    d_result = ''.join(map_result)

result_list.append(c_result)
result_list.append(d_result)

e = list(map(int, result_list))
print(sorted(e)[1])

Solution (Python):
n=input().split()
te = n[0]*int(n[1])
re = n[1]*int(n[0])
list=[te,re]
rest = sorted(list)
print(rest[0])

Solution (Python):

a, b = input().split()

int_a = int(a)
int_b = int(b)

a_List = ''
b_List = ''

for i in range(int_a):
    b_List = b_List + b

for i in range(int_b):
    a_List = a_List + a





a_List = int(a_List)
b_List = int(b_List)

if a_List >= b_List:
    print(a_List)

else:
    print(b_List)