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();
		int[] arrayA = new int[b];
		int[] arrayB = new int[a];
		String amozi = "";
		String bmozi = "";


		for(int i=0;i<b;i++) {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		}

		for(int i=0;i<a;i++) {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		}

		System.out.println(arrayA[0]>=arrayB[0]?bmozi:amozi);

		scan.close();

	}

} 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();
		int[] arrayA = new int[b];
		int[] arrayB = new int[a];
		String amozi = "";
		String bmozi = "";


		for(int i=0;i<b;i++) {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		}

		for(int i=0;i<a;i++) {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		}

		System.out.println(arrayA[0]>=arrayB[0]?bmozi:amozi);

		scan.close();

	}

} Main public static void main(String[] args) {

		Scanner scan = new Scanner(System.in);

		int a = scan.nextInt();
		int b = scan.nextInt();
		int[] arrayA = new int[b];
		int[] arrayB = new int[a];
		String amozi = "";
		String bmozi = "";


		for(int i=0;i<b;i++) {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		}

		for(int i=0;i<a;i++) {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		}

		System.out.println(arrayA[0]>=arrayB[0]?bmozi:amozi);

		scan.close();

	} main {

		Scanner scan = new Scanner(System.in);

		int a = scan.nextInt();
		int b = scan.nextInt();
		int[] arrayA = new int[b];
		int[] arrayB = new int[a];
		String amozi = "";
		String bmozi = "";


		for(int i=0;i<b;i++) {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		}

		for(int i=0;i<a;i++) {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		}

		System.out.println(arrayA[0]>=arrayB[0]?bmozi:amozi);

		scan.close();

	} 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 int[] arrayA = new int[b]; arrayA new int[b] b int[] arrayB = new int[a]; arrayB new int[a] a String amozi = ""; amozi "" String bmozi = ""; bmozi "" for(int i=0;i<b;i++) {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		} int i=0; int i=0; i 0 i<b i b i++ i++ i {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		} {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		} arrayA[i] = a arrayA[i] arrayA i a amozi = amozi + String.valueOf(arrayA[i]) amozi amozi + String.valueOf(arrayA[i]) amozi String.valueOf(arrayA[i]) String.valueOf String arrayA[i] arrayA i for(int i=0;i<a;i++) {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		} int i=0; int i=0; i 0 i<a i a i++ i++ i {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		} {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		} arrayB[i] = b arrayB[i] arrayB i b bmozi = bmozi + String.valueOf(arrayB[i]) bmozi bmozi + String.valueOf(arrayB[i]) bmozi String.valueOf(arrayB[i]) String.valueOf String arrayB[i] arrayB i System.out.println(arrayA[0]>=arrayB[0]?bmozi:amozi) System.out.println System.out System System.out arrayA[0]>=arrayB[0]?bmozi:amozi arrayA[0]>=arrayB[0] arrayA[0] arrayA 0 arrayB[0] arrayB 0 bmozi amozi scan.close() scan.close scan 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();
		int[] arrayA = new int[b];
		int[] arrayB = new int[a];
		String amozi = "";
		String bmozi = "";


		for(int i=0;i<b;i++) {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		}

		for(int i=0;i<a;i++) {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		}

		System.out.println(arrayA[0]>=arrayB[0]?bmozi:amozi);

		scan.close();

	}

} public class Main {

	public static void main(String[] args) {

		Scanner scan = new Scanner(System.in);

		int a = scan.nextInt();
		int b = scan.nextInt();
		int[] arrayA = new int[b];
		int[] arrayB = new int[a];
		String amozi = "";
		String bmozi = "";


		for(int i=0;i<b;i++) {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		}

		for(int i=0;i<a;i++) {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		}

		System.out.println(arrayA[0]>=arrayB[0]?bmozi:amozi);

		scan.close();

	}

} 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();
		int[] arrayA = new int[b];
		int[] arrayB = new int[a];
		String amozi = "";
		String bmozi = "";


		for(int i=0;i<b;i++) {
			arrayA[i] = a;
			amozi = amozi + String.valueOf(arrayA[i]);

		}

		for(int i=0;i<a;i++) {
			arrayB[i] = b;
			bmozi = bmozi + String.valueOf(arrayB[i]);
		}

		System.out.println(arrayA[0]>=arrayB[0]?bmozi:amozi);

		scan.close();

	}

}
