import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		// 自分の得意な言語で
		// Let's チャレンジ！！

		Scanner sc = new Scanner(System.in);

		int n = sc.nextInt();
		int m = sc.nextInt();

		String nStr = "";
		String mStr = "";

		for (int i = 0; i < m; i++) {
			nStr += n;
		}

		for (int i = 0; i < n; i++) {
			mStr += m;
		}
		String re = mStr;

		if (nStr.compareTo(mStr) < 0) {
			re = nStr;
		}

		System.out.println(re);

	}

} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		// 自分の得意な言語で
		// Let's チャレンジ！！

		Scanner sc = new Scanner(System.in);

		int n = sc.nextInt();
		int m = sc.nextInt();

		String nStr = "";
		String mStr = "";

		for (int i = 0; i < m; i++) {
			nStr += n;
		}

		for (int i = 0; i < n; i++) {
			mStr += m;
		}
		String re = mStr;

		if (nStr.compareTo(mStr) < 0) {
			re = nStr;
		}

		System.out.println(re);

	}

} Main public static void main(String[] args) {
		// 自分の得意な言語で
		// Let's チャレンジ！！

		Scanner sc = new Scanner(System.in);

		int n = sc.nextInt();
		int m = sc.nextInt();

		String nStr = "";
		String mStr = "";

		for (int i = 0; i < m; i++) {
			nStr += n;
		}

		for (int i = 0; i < n; i++) {
			mStr += m;
		}
		String re = mStr;

		if (nStr.compareTo(mStr) < 0) {
			re = nStr;
		}

		System.out.println(re);

	} main {
		// 自分の得意な言語で
		// Let's チャレンジ！！

		Scanner sc = new Scanner(System.in);

		int n = sc.nextInt();
		int m = sc.nextInt();

		String nStr = "";
		String mStr = "";

		for (int i = 0; i < m; i++) {
			nStr += n;
		}

		for (int i = 0; i < n; i++) {
			mStr += m;
		}
		String re = mStr;

		if (nStr.compareTo(mStr) < 0) {
			re = nStr;
		}

		System.out.println(re);

	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int m = sc.nextInt(); m sc.nextInt() sc.nextInt sc String nStr = ""; nStr "" String mStr = ""; mStr "" for (int i = 0; i < m; i++) {
			nStr += n;
		} int i = 0; int i = 0; i 0 i < m i m i++ i++ i {
			nStr += n;
		} {
			nStr += n;
		} nStr += n nStr n for (int i = 0; i < n; i++) {
			mStr += m;
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			mStr += m;
		} {
			mStr += m;
		} mStr += m mStr m String re = mStr; re mStr if (nStr.compareTo(mStr) < 0) {
			re = nStr;
		} nStr.compareTo(mStr) < 0 nStr.compareTo(mStr) nStr.compareTo nStr mStr 0 {
			re = nStr;
		} re = nStr re nStr System.out.println(re) System.out.println System.out System System.out re String[] args args public class Main {
	public static void main(String[] args) {
		// 自分の得意な言語で
		// Let's チャレンジ！！

		Scanner sc = new Scanner(System.in);

		int n = sc.nextInt();
		int m = sc.nextInt();

		String nStr = "";
		String mStr = "";

		for (int i = 0; i < m; i++) {
			nStr += n;
		}

		for (int i = 0; i < n; i++) {
			mStr += m;
		}
		String re = mStr;

		if (nStr.compareTo(mStr) < 0) {
			re = nStr;
		}

		System.out.println(re);

	}

} public class Main {
	public static void main(String[] args) {
		// 自分の得意な言語で
		// Let's チャレンジ！！

		Scanner sc = new Scanner(System.in);

		int n = sc.nextInt();
		int m = sc.nextInt();

		String nStr = "";
		String mStr = "";

		for (int i = 0; i < m; i++) {
			nStr += n;
		}

		for (int i = 0; i < n; i++) {
			mStr += m;
		}
		String re = mStr;

		if (nStr.compareTo(mStr) < 0) {
			re = nStr;
		}

		System.out.println(re);

	}

} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		// 自分の得意な言語で
		// Let's チャレンジ！！

		Scanner sc = new Scanner(System.in);

		int n = sc.nextInt();
		int m = sc.nextInt();

		String nStr = "";
		String mStr = "";

		for (int i = 0; i < m; i++) {
			nStr += n;
		}

		for (int i = 0; i < n; i++) {
			mStr += m;
		}
		String re = mStr;

		if (nStr.compareTo(mStr) < 0) {
			re = nStr;
		}

		System.out.println(re);

	}

}