import java.util.*;
class Main{
	public static void main(String[]args){
    	Scanner in = new Scanner(System.in);
      	int a = in.nextInt(), b = in.nextInt();
      	String x = "", y = "";
      	for(int i = 0; i < a ;i++)
          x+=b;
      	for(int i = 0 ; i< b;i++)
          y+=a;
      	if(Integer.parseInt(x)>Integer.parseInt(y))
          System.out.println(x);
      	else
          System.out.println(y);
    }
} import java.util.*; util.* java class Main{
	public static void main(String[]args){
    	Scanner in = new Scanner(System.in);
      	int a = in.nextInt(), b = in.nextInt();
      	String x = "", y = "";
      	for(int i = 0; i < a ;i++)
          x+=b;
      	for(int i = 0 ; i< b;i++)
          y+=a;
      	if(Integer.parseInt(x)>Integer.parseInt(y))
          System.out.println(x);
      	else
          System.out.println(y);
    }
} Main public static void main(String[]args){
    	Scanner in = new Scanner(System.in);
      	int a = in.nextInt(), b = in.nextInt();
      	String x = "", y = "";
      	for(int i = 0; i < a ;i++)
          x+=b;
      	for(int i = 0 ; i< b;i++)
          y+=a;
      	if(Integer.parseInt(x)>Integer.parseInt(y))
          System.out.println(x);
      	else
          System.out.println(y);
    } main {
    	Scanner in = new Scanner(System.in);
      	int a = in.nextInt(), b = in.nextInt();
      	String x = "", y = "";
      	for(int i = 0; i < a ;i++)
          x+=b;
      	for(int i = 0 ; i< b;i++)
          y+=a;
      	if(Integer.parseInt(x)>Integer.parseInt(y))
          System.out.println(x);
      	else
          System.out.println(y);
    } Scanner in = new Scanner(System.in); in new Scanner(System.in) int a = in.nextInt() a in.nextInt() in.nextInt in b = in.nextInt(); b in.nextInt() in.nextInt in String x = "" x "" y = ""; y "" for(int i = 0; i < a ;i++)
          x+=b; int i = 0; int i = 0; i 0 i < a i a i++ i++ i x+=b; x+=b x b for(int i = 0 ; i< b;i++)
          y+=a; int i = 0 ; int i = 0 ; i 0 i< b i b i++ i++ i y+=a; y+=a y a if(Integer.parseInt(x)>Integer.parseInt(y))
          System.out.println(x);
      	else
          System.out.println(y); Integer.parseInt(x)>Integer.parseInt(y) Integer.parseInt(x) Integer.parseInt Integer x Integer.parseInt(y) Integer.parseInt Integer y System.out.println(x) System.out.println System.out System System.out x System.out.println(y) System.out.println System.out System System.out y String[]args args
import java.util.*;
class Main{
	public static void main(String[]args){
    	Scanner in = new Scanner(System.in);
      	int a = in.nextInt(), b = in.nextInt();
      	String x = "", y = "";
      	for(int i = 0; i < a ;i++)
          x+=b;
      	for(int i = 0 ; i< b;i++)
          y+=a;
      	if(Integer.parseInt(x)>Integer.parseInt(y))
          System.out.println(x);
      	else
          System.out.println(y);
    }
}