import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ

		Scanner scanner = new Scanner(System.in);

		//入力表示
		String  a = scanner.next();
		String  b = scanner.next();
		
		//文字の繰り返し表示
		String c = "";
		for(int i =0; i<Integer.parseInt(b); i++) {
			c=c+a;
		}
		
		String d = "";
		for (int i =0; i<Integer.parseInt(a); i++) {
			d=d+b;
		}
		
		if (c.compareTo(d) == 0) {
			System.out.println(c);
	
		}
		if (c.compareTo(d) < 0) {
			System.out.println(c);
		}
		
		if (c.compareTo(d) > 0) {
			System.out.println(d);
		}

		scanner.close();
	}
} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ

		Scanner scanner = new Scanner(System.in);

		//入力表示
		String  a = scanner.next();
		String  b = scanner.next();
		
		//文字の繰り返し表示
		String c = "";
		for(int i =0; i<Integer.parseInt(b); i++) {
			c=c+a;
		}
		
		String d = "";
		for (int i =0; i<Integer.parseInt(a); i++) {
			d=d+b;
		}
		
		if (c.compareTo(d) == 0) {
			System.out.println(c);
	
		}
		if (c.compareTo(d) < 0) {
			System.out.println(c);
		}
		
		if (c.compareTo(d) > 0) {
			System.out.println(d);
		}

		scanner.close();
	}
} Main public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ

		Scanner scanner = new Scanner(System.in);

		//入力表示
		String  a = scanner.next();
		String  b = scanner.next();
		
		//文字の繰り返し表示
		String c = "";
		for(int i =0; i<Integer.parseInt(b); i++) {
			c=c+a;
		}
		
		String d = "";
		for (int i =0; i<Integer.parseInt(a); i++) {
			d=d+b;
		}
		
		if (c.compareTo(d) == 0) {
			System.out.println(c);
	
		}
		if (c.compareTo(d) < 0) {
			System.out.println(c);
		}
		
		if (c.compareTo(d) > 0) {
			System.out.println(d);
		}

		scanner.close();
	} main {
		// TODO 自動生成されたメソッド・スタブ

		Scanner scanner = new Scanner(System.in);

		//入力表示
		String  a = scanner.next();
		String  b = scanner.next();
		
		//文字の繰り返し表示
		String c = "";
		for(int i =0; i<Integer.parseInt(b); i++) {
			c=c+a;
		}
		
		String d = "";
		for (int i =0; i<Integer.parseInt(a); i++) {
			d=d+b;
		}
		
		if (c.compareTo(d) == 0) {
			System.out.println(c);
	
		}
		if (c.compareTo(d) < 0) {
			System.out.println(c);
		}
		
		if (c.compareTo(d) > 0) {
			System.out.println(d);
		}

		scanner.close();
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) String  a = scanner.next(); a scanner.next() scanner.next scanner String  b = scanner.next(); b scanner.next() scanner.next scanner String c = ""; c "" for(int i =0; i<Integer.parseInt(b); i++) {
			c=c+a;
		} int i =0; int i =0; i 0 i<Integer.parseInt(b) i Integer.parseInt(b) Integer.parseInt Integer b i++ i++ i {
			c=c+a;
		} {
			c=c+a;
		} c=c+a c c+a c a String d = ""; d "" for (int i =0; i<Integer.parseInt(a); i++) {
			d=d+b;
		} int i =0; int i =0; i 0 i<Integer.parseInt(a) i Integer.parseInt(a) Integer.parseInt Integer a i++ i++ i {
			d=d+b;
		} {
			d=d+b;
		} d=d+b d d+b d b if (c.compareTo(d) == 0) {
			System.out.println(c);
	
		} c.compareTo(d) == 0 c.compareTo(d) c.compareTo c d 0 {
			System.out.println(c);
	
		} System.out.println(c) System.out.println System.out System System.out c if (c.compareTo(d) < 0) {
			System.out.println(c);
		} c.compareTo(d) < 0 c.compareTo(d) c.compareTo c d 0 {
			System.out.println(c);
		} System.out.println(c) System.out.println System.out System System.out c if (c.compareTo(d) > 0) {
			System.out.println(d);
		} c.compareTo(d) > 0 c.compareTo(d) c.compareTo c d 0 {
			System.out.println(d);
		} System.out.println(d) System.out.println System.out System System.out d scanner.close() scanner.close scanner String[] args args public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ

		Scanner scanner = new Scanner(System.in);

		//入力表示
		String  a = scanner.next();
		String  b = scanner.next();
		
		//文字の繰り返し表示
		String c = "";
		for(int i =0; i<Integer.parseInt(b); i++) {
			c=c+a;
		}
		
		String d = "";
		for (int i =0; i<Integer.parseInt(a); i++) {
			d=d+b;
		}
		
		if (c.compareTo(d) == 0) {
			System.out.println(c);
	
		}
		if (c.compareTo(d) < 0) {
			System.out.println(c);
		}
		
		if (c.compareTo(d) > 0) {
			System.out.println(d);
		}

		scanner.close();
	}
} public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ

		Scanner scanner = new Scanner(System.in);

		//入力表示
		String  a = scanner.next();
		String  b = scanner.next();
		
		//文字の繰り返し表示
		String c = "";
		for(int i =0; i<Integer.parseInt(b); i++) {
			c=c+a;
		}
		
		String d = "";
		for (int i =0; i<Integer.parseInt(a); i++) {
			d=d+b;
		}
		
		if (c.compareTo(d) == 0) {
			System.out.println(c);
	
		}
		if (c.compareTo(d) < 0) {
			System.out.println(c);
		}
		
		if (c.compareTo(d) > 0) {
			System.out.println(d);
		}

		scanner.close();
	}
} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ

		Scanner scanner = new Scanner(System.in);

		//入力表示
		String  a = scanner.next();
		String  b = scanner.next();
		
		//文字の繰り返し表示
		String c = "";
		for(int i =0; i<Integer.parseInt(b); i++) {
			c=c+a;
		}
		
		String d = "";
		for (int i =0; i<Integer.parseInt(a); i++) {
			d=d+b;
		}
		
		if (c.compareTo(d) == 0) {
			System.out.println(c);
	
		}
		if (c.compareTo(d) < 0) {
			System.out.println(c);
		}
		
		if (c.compareTo(d) > 0) {
			System.out.println(d);
		}

		scanner.close();
	}
}
