program main

  implicit none
  integer :: a,b
  integer :: aa, bb
  integer :: i, j, k
  character(9) :: caa, cbb

  read(*,*) a, b
  
  aa = 0 
  do i = 1, a 
    aa = aa+b*10**(i-1)
  end do

  bb = 0 
  do i = 1, b 
    bb = bb+a*10**(i-1)
  end do
  
  
  if( a > b ) then
    print*, aa 
  else 
    print*, bb 
  end if 
    
end program main
