import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		StringBuilder sb1 = new StringBuilder();
		StringBuilder sb2 = new StringBuilder();

		for (int i = 0; i < a; i++) {
			sb1.append(b);

		}

		for (int i = 0; i < b; i++) {
			sb2.append(a);
		}

		if (sb1.toString().compareTo(sb2.toString()) < 0) {
			System.out.println(sb1);
		} else {
			System.out.println(sb2);
		}

	}
} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		StringBuilder sb1 = new StringBuilder();
		StringBuilder sb2 = new StringBuilder();

		for (int i = 0; i < a; i++) {
			sb1.append(b);

		}

		for (int i = 0; i < b; i++) {
			sb2.append(a);
		}

		if (sb1.toString().compareTo(sb2.toString()) < 0) {
			System.out.println(sb1);
		} else {
			System.out.println(sb2);
		}

	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		StringBuilder sb1 = new StringBuilder();
		StringBuilder sb2 = new StringBuilder();

		for (int i = 0; i < a; i++) {
			sb1.append(b);

		}

		for (int i = 0; i < b; i++) {
			sb2.append(a);
		}

		if (sb1.toString().compareTo(sb2.toString()) < 0) {
			System.out.println(sb1);
		} else {
			System.out.println(sb2);
		}

	} main {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		StringBuilder sb1 = new StringBuilder();
		StringBuilder sb2 = new StringBuilder();

		for (int i = 0; i < a; i++) {
			sb1.append(b);

		}

		for (int i = 0; i < b; i++) {
			sb2.append(a);
		}

		if (sb1.toString().compareTo(sb2.toString()) < 0) {
			System.out.println(sb1);
		} else {
			System.out.println(sb2);
		}

	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc StringBuilder sb1 = new StringBuilder(); sb1 new StringBuilder() StringBuilder sb2 = new StringBuilder(); sb2 new StringBuilder() for (int i = 0; i < a; i++) {
			sb1.append(b);

		} int i = 0; int i = 0; i 0 i < a i a i++ i++ i {
			sb1.append(b);

		} {
			sb1.append(b);

		} sb1.append(b) sb1.append sb1 b for (int i = 0; i < b; i++) {
			sb2.append(a);
		} int i = 0; int i = 0; i 0 i < b i b i++ i++ i {
			sb2.append(a);
		} {
			sb2.append(a);
		} sb2.append(a) sb2.append sb2 a if (sb1.toString().compareTo(sb2.toString()) < 0) {
			System.out.println(sb1);
		} else {
			System.out.println(sb2);
		} sb1.toString().compareTo(sb2.toString()) < 0 sb1.toString().compareTo(sb2.toString()) sb1.toString().compareTo sb1.toString() sb1.toString sb1 sb2.toString() sb2.toString sb2 0 {
			System.out.println(sb1);
		} System.out.println(sb1) System.out.println System.out System System.out sb1 {
			System.out.println(sb2);
		} System.out.println(sb2) System.out.println System.out System System.out sb2 String[] args args public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		StringBuilder sb1 = new StringBuilder();
		StringBuilder sb2 = new StringBuilder();

		for (int i = 0; i < a; i++) {
			sb1.append(b);

		}

		for (int i = 0; i < b; i++) {
			sb2.append(a);
		}

		if (sb1.toString().compareTo(sb2.toString()) < 0) {
			System.out.println(sb1);
		} else {
			System.out.println(sb2);
		}

	}
} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		StringBuilder sb1 = new StringBuilder();
		StringBuilder sb2 = new StringBuilder();

		for (int i = 0; i < a; i++) {
			sb1.append(b);

		}

		for (int i = 0; i < b; i++) {
			sb2.append(a);
		}

		if (sb1.toString().compareTo(sb2.toString()) < 0) {
			System.out.println(sb1);
		} else {
			System.out.println(sb2);
		}

	}
} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();

		StringBuilder sb1 = new StringBuilder();
		StringBuilder sb2 = new StringBuilder();

		for (int i = 0; i < a; i++) {
			sb1.append(b);

		}

		for (int i = 0; i < b; i++) {
			sb2.append(a);
		}

		if (sb1.toString().compareTo(sb2.toString()) < 0) {
			System.out.println(sb1);
		} else {
			System.out.println(sb2);
		}

	}
}
