import java.util.Arrays;
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();
        String[] s = new String[2];
        StringBuilder sba = new StringBuilder();
        for (int i = 0; i < b; i++) {
            sba.append(a);
        }
        s[0] = sba.toString();
        StringBuilder sbb = new StringBuilder();
        for (int i = 0; i < a; i++) {
            sbb.append(b);
        }
        s[1] = sbb.toString();
        Arrays.sort(s);
        System.out.println(s[0]);
    }

} import java.util.Arrays; Arrays java.util 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();
        String[] s = new String[2];
        StringBuilder sba = new StringBuilder();
        for (int i = 0; i < b; i++) {
            sba.append(a);
        }
        s[0] = sba.toString();
        StringBuilder sbb = new StringBuilder();
        for (int i = 0; i < a; i++) {
            sbb.append(b);
        }
        s[1] = sbb.toString();
        Arrays.sort(s);
        System.out.println(s[0]);
    }

} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        String[] s = new String[2];
        StringBuilder sba = new StringBuilder();
        for (int i = 0; i < b; i++) {
            sba.append(a);
        }
        s[0] = sba.toString();
        StringBuilder sbb = new StringBuilder();
        for (int i = 0; i < a; i++) {
            sbb.append(b);
        }
        s[1] = sbb.toString();
        Arrays.sort(s);
        System.out.println(s[0]);
    } main {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        String[] s = new String[2];
        StringBuilder sba = new StringBuilder();
        for (int i = 0; i < b; i++) {
            sba.append(a);
        }
        s[0] = sba.toString();
        StringBuilder sbb = new StringBuilder();
        for (int i = 0; i < a; i++) {
            sbb.append(b);
        }
        s[1] = sbb.toString();
        Arrays.sort(s);
        System.out.println(s[0]);
    } 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 String[] s = new String[2]; s new String[2] 2 StringBuilder sba = new StringBuilder(); sba new StringBuilder() for (int i = 0; i < b; i++) {
            sba.append(a);
        } int i = 0; int i = 0; i 0 i < b i b i++ i++ i {
            sba.append(a);
        } {
            sba.append(a);
        } sba.append(a) sba.append sba a s[0] = sba.toString() s[0] s 0 sba.toString() sba.toString sba StringBuilder sbb = new StringBuilder(); sbb new StringBuilder() for (int i = 0; i < a; i++) {
            sbb.append(b);
        } int i = 0; int i = 0; i 0 i < a i a i++ i++ i {
            sbb.append(b);
        } {
            sbb.append(b);
        } sbb.append(b) sbb.append sbb b s[1] = sbb.toString() s[1] s 1 sbb.toString() sbb.toString sbb Arrays.sort(s) Arrays.sort Arrays s System.out.println(s[0]) System.out.println System.out System System.out s[0] s 0 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();
        String[] s = new String[2];
        StringBuilder sba = new StringBuilder();
        for (int i = 0; i < b; i++) {
            sba.append(a);
        }
        s[0] = sba.toString();
        StringBuilder sbb = new StringBuilder();
        for (int i = 0; i < a; i++) {
            sbb.append(b);
        }
        s[1] = sbb.toString();
        Arrays.sort(s);
        System.out.println(s[0]);
    }

} public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        String[] s = new String[2];
        StringBuilder sba = new StringBuilder();
        for (int i = 0; i < b; i++) {
            sba.append(a);
        }
        s[0] = sba.toString();
        StringBuilder sbb = new StringBuilder();
        for (int i = 0; i < a; i++) {
            sbb.append(b);
        }
        s[1] = sbb.toString();
        Arrays.sort(s);
        System.out.println(s[0]);
    }

} Main
import java.util.Arrays;
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();
        String[] s = new String[2];
        StringBuilder sba = new StringBuilder();
        for (int i = 0; i < b; i++) {
            sba.append(a);
        }
        s[0] = sba.toString();
        StringBuilder sbb = new StringBuilder();
        for (int i = 0; i < a; i++) {
            sbb.append(b);
        }
        s[1] = sbb.toString();
        Arrays.sort(s);
        System.out.println(s[0]);
    }

}
