function main(input)
{
  var line = input[0].split(' ');
  var smaller = Math.min(line[0], line[1]);
  var other = Math.max(line[0], line[1]);
  
  var res = ''
  for (var i = 1; i <= other; i++){
  	res += smaller
  }
  console.log(res)
  
}


main(require('fs').readFileSync('/dev/stdin', 'utf8').trim().split("\n"))