import java.util.Scanner;

public class Main {
	public static void main (String args[]) {
		Scanner scan = new Scanner(System.in);
		int a = scan.nextInt();
		int b = scan.nextInt();
		String stra = "";
		String strb = "";
		for(int i = 0; i < a; i++) {
			stra = stra + String.valueOf(b);
		}
		for(int i = 0; i < b; i++) {
			strb = strb + String.valueOf(a);
		}
		if(stra.compareTo(strb) <= 0) {
			System.out.println(stra);
		} else {
			System.out.println(strb);
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main (String args[]) {
		Scanner scan = new Scanner(System.in);
		int a = scan.nextInt();
		int b = scan.nextInt();
		String stra = "";
		String strb = "";
		for(int i = 0; i < a; i++) {
			stra = stra + String.valueOf(b);
		}
		for(int i = 0; i < b; i++) {
			strb = strb + String.valueOf(a);
		}
		if(stra.compareTo(strb) <= 0) {
			System.out.println(stra);
		} else {
			System.out.println(strb);
		}
	}
} Main public static void main (String args[]) {
		Scanner scan = new Scanner(System.in);
		int a = scan.nextInt();
		int b = scan.nextInt();
		String stra = "";
		String strb = "";
		for(int i = 0; i < a; i++) {
			stra = stra + String.valueOf(b);
		}
		for(int i = 0; i < b; i++) {
			strb = strb + String.valueOf(a);
		}
		if(stra.compareTo(strb) <= 0) {
			System.out.println(stra);
		} else {
			System.out.println(strb);
		}
	} main {
		Scanner scan = new Scanner(System.in);
		int a = scan.nextInt();
		int b = scan.nextInt();
		String stra = "";
		String strb = "";
		for(int i = 0; i < a; i++) {
			stra = stra + String.valueOf(b);
		}
		for(int i = 0; i < b; i++) {
			strb = strb + String.valueOf(a);
		}
		if(stra.compareTo(strb) <= 0) {
			System.out.println(stra);
		} else {
			System.out.println(strb);
		}
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int a = scan.nextInt(); a scan.nextInt() scan.nextInt scan int b = scan.nextInt(); b scan.nextInt() scan.nextInt scan String stra = ""; stra "" String strb = ""; strb "" for(int i = 0; i < a; i++) {
			stra = stra + String.valueOf(b);
		} int i = 0; int i = 0; i 0 i < a i a i++ i++ i {
			stra = stra + String.valueOf(b);
		} {
			stra = stra + String.valueOf(b);
		} stra = stra + String.valueOf(b) stra stra + String.valueOf(b) stra String.valueOf(b) String.valueOf String b for(int i = 0; i < b; i++) {
			strb = strb + String.valueOf(a);
		} int i = 0; int i = 0; i 0 i < b i b i++ i++ i {
			strb = strb + String.valueOf(a);
		} {
			strb = strb + String.valueOf(a);
		} strb = strb + String.valueOf(a) strb strb + String.valueOf(a) strb String.valueOf(a) String.valueOf String a if(stra.compareTo(strb) <= 0) {
			System.out.println(stra);
		} else {
			System.out.println(strb);
		} stra.compareTo(strb) <= 0 stra.compareTo(strb) stra.compareTo stra strb 0 {
			System.out.println(stra);
		} System.out.println(stra) System.out.println System.out System System.out stra {
			System.out.println(strb);
		} System.out.println(strb) System.out.println System.out System System.out strb String args[] args public class Main {
	public static void main (String args[]) {
		Scanner scan = new Scanner(System.in);
		int a = scan.nextInt();
		int b = scan.nextInt();
		String stra = "";
		String strb = "";
		for(int i = 0; i < a; i++) {
			stra = stra + String.valueOf(b);
		}
		for(int i = 0; i < b; i++) {
			strb = strb + String.valueOf(a);
		}
		if(stra.compareTo(strb) <= 0) {
			System.out.println(stra);
		} else {
			System.out.println(strb);
		}
	}
} public class Main {
	public static void main (String args[]) {
		Scanner scan = new Scanner(System.in);
		int a = scan.nextInt();
		int b = scan.nextInt();
		String stra = "";
		String strb = "";
		for(int i = 0; i < a; i++) {
			stra = stra + String.valueOf(b);
		}
		for(int i = 0; i < b; i++) {
			strb = strb + String.valueOf(a);
		}
		if(stra.compareTo(strb) <= 0) {
			System.out.println(stra);
		} else {
			System.out.println(strb);
		}
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main (String args[]) {
		Scanner scan = new Scanner(System.in);
		int a = scan.nextInt();
		int b = scan.nextInt();
		String stra = "";
		String strb = "";
		for(int i = 0; i < a; i++) {
			stra = stra + String.valueOf(b);
		}
		for(int i = 0; i < b; i++) {
			strb = strb + String.valueOf(a);
		}
		if(stra.compareTo(strb) <= 0) {
			System.out.println(stra);
		} else {
			System.out.println(strb);
		}
	}
}