import java.util.*;

public class Main{
    public static void main(String[] arg){
        Scanner sc = new Scanner(System.in);

        int a = sc.nextInt();
        int b = sc.nextInt();
        String a1 = String.valueOf(a);
        String b1 = String.valueOf(b);
        String A = b1;
        String B = a1;

        for(int i=1; i<a; i++){
            A = A + b1;
        }
        for(int i=1; i<b; i++){
            B = B + a1;
        }
        int A1 = Integer.parseInt(A);
        int B1 = Integer.parseInt(B);
        if(A1<=B1){
            System.out.println(B);
        }
        else{
            System.out.println(A);
        }
    }
} import java.util.*; util.* java public class Main{
    public static void main(String[] arg){
        Scanner sc = new Scanner(System.in);

        int a = sc.nextInt();
        int b = sc.nextInt();
        String a1 = String.valueOf(a);
        String b1 = String.valueOf(b);
        String A = b1;
        String B = a1;

        for(int i=1; i<a; i++){
            A = A + b1;
        }
        for(int i=1; i<b; i++){
            B = B + a1;
        }
        int A1 = Integer.parseInt(A);
        int B1 = Integer.parseInt(B);
        if(A1<=B1){
            System.out.println(B);
        }
        else{
            System.out.println(A);
        }
    }
} Main public static void main(String[] arg){
        Scanner sc = new Scanner(System.in);

        int a = sc.nextInt();
        int b = sc.nextInt();
        String a1 = String.valueOf(a);
        String b1 = String.valueOf(b);
        String A = b1;
        String B = a1;

        for(int i=1; i<a; i++){
            A = A + b1;
        }
        for(int i=1; i<b; i++){
            B = B + a1;
        }
        int A1 = Integer.parseInt(A);
        int B1 = Integer.parseInt(B);
        if(A1<=B1){
            System.out.println(B);
        }
        else{
            System.out.println(A);
        }
    } main {
        Scanner sc = new Scanner(System.in);

        int a = sc.nextInt();
        int b = sc.nextInt();
        String a1 = String.valueOf(a);
        String b1 = String.valueOf(b);
        String A = b1;
        String B = a1;

        for(int i=1; i<a; i++){
            A = A + b1;
        }
        for(int i=1; i<b; i++){
            B = B + a1;
        }
        int A1 = Integer.parseInt(A);
        int B1 = Integer.parseInt(B);
        if(A1<=B1){
            System.out.println(B);
        }
        else{
            System.out.println(A);
        }
    } 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 a1 = String.valueOf(a); a1 String.valueOf(a) String.valueOf String a String b1 = String.valueOf(b); b1 String.valueOf(b) String.valueOf String b String A = b1; A b1 String B = a1; B a1 for(int i=1; i<a; i++){
            A = A + b1;
        } int i=1; int i=1; i 1 i<a i a i++ i++ i {
            A = A + b1;
        } {
            A = A + b1;
        } A = A + b1 A A + b1 A b1 for(int i=1; i<b; i++){
            B = B + a1;
        } int i=1; int i=1; i 1 i<b i b i++ i++ i {
            B = B + a1;
        } {
            B = B + a1;
        } B = B + a1 B B + a1 B a1 int A1 = Integer.parseInt(A); A1 Integer.parseInt(A) Integer.parseInt Integer A int B1 = Integer.parseInt(B); B1 Integer.parseInt(B) Integer.parseInt Integer B if(A1<=B1){
            System.out.println(B);
        }
        else{
            System.out.println(A);
        } A1<=B1 A1 B1 {
            System.out.println(B);
        } System.out.println(B) System.out.println System.out System System.out B {
            System.out.println(A);
        } System.out.println(A) System.out.println System.out System System.out A String[] arg arg public class Main{
    public static void main(String[] arg){
        Scanner sc = new Scanner(System.in);

        int a = sc.nextInt();
        int b = sc.nextInt();
        String a1 = String.valueOf(a);
        String b1 = String.valueOf(b);
        String A = b1;
        String B = a1;

        for(int i=1; i<a; i++){
            A = A + b1;
        }
        for(int i=1; i<b; i++){
            B = B + a1;
        }
        int A1 = Integer.parseInt(A);
        int B1 = Integer.parseInt(B);
        if(A1<=B1){
            System.out.println(B);
        }
        else{
            System.out.println(A);
        }
    }
} public class Main{
    public static void main(String[] arg){
        Scanner sc = new Scanner(System.in);

        int a = sc.nextInt();
        int b = sc.nextInt();
        String a1 = String.valueOf(a);
        String b1 = String.valueOf(b);
        String A = b1;
        String B = a1;

        for(int i=1; i<a; i++){
            A = A + b1;
        }
        for(int i=1; i<b; i++){
            B = B + a1;
        }
        int A1 = Integer.parseInt(A);
        int B1 = Integer.parseInt(B);
        if(A1<=B1){
            System.out.println(B);
        }
        else{
            System.out.println(A);
        }
    }
} Main
import java.util.*;

public class Main{
    public static void main(String[] arg){
        Scanner sc = new Scanner(System.in);

        int a = sc.nextInt();
        int b = sc.nextInt();
        String a1 = String.valueOf(a);
        String b1 = String.valueOf(b);
        String A = b1;
        String B = a1;

        for(int i=1; i<a; i++){
            A = A + b1;
        }
        for(int i=1; i<b; i++){
            B = B + a1;
        }
        int A1 = Integer.parseInt(A);
        int B1 = Integer.parseInt(B);
        if(A1<=B1){
            System.out.println(B);
        }
        else{
            System.out.println(A);
        }
    }
}