import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scanner = new Scanner(System.in);
        String a = scanner.next(); //文字列a
        int A = Integer.parseInt(a); //数字A
        String b = scanner.next(); //文字列b
        int B = Integer.parseInt(b); //数字B
        
        String a_sum = "";
        String b_sum = "";
        
        for(int i=0; i<B; i++){
            a_sum = a_sum +a;
        }
        
        for(int i=0; i<A; i++){
            b_sum = b_sum +b;
        }
        
        int A_sum = Integer.parseInt(a_sum);
        int B_sum = Integer.parseInt(b_sum);
        
        if(A<=B){
            System.out.println(A_sum);
        }else{
            System.out.println(B_sum);
        }
        
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scanner = new Scanner(System.in);
        String a = scanner.next(); //文字列a
        int A = Integer.parseInt(a); //数字A
        String b = scanner.next(); //文字列b
        int B = Integer.parseInt(b); //数字B
        
        String a_sum = "";
        String b_sum = "";
        
        for(int i=0; i<B; i++){
            a_sum = a_sum +a;
        }
        
        for(int i=0; i<A; i++){
            b_sum = b_sum +b;
        }
        
        int A_sum = Integer.parseInt(a_sum);
        int B_sum = Integer.parseInt(b_sum);
        
        if(A<=B){
            System.out.println(A_sum);
        }else{
            System.out.println(B_sum);
        }
        
    }
} Main public static void main(String[] args) throws Exception {
        
        Scanner scanner = new Scanner(System.in);
        String a = scanner.next(); //文字列a
        int A = Integer.parseInt(a); //数字A
        String b = scanner.next(); //文字列b
        int B = Integer.parseInt(b); //数字B
        
        String a_sum = "";
        String b_sum = "";
        
        for(int i=0; i<B; i++){
            a_sum = a_sum +a;
        }
        
        for(int i=0; i<A; i++){
            b_sum = b_sum +b;
        }
        
        int A_sum = Integer.parseInt(a_sum);
        int B_sum = Integer.parseInt(b_sum);
        
        if(A<=B){
            System.out.println(A_sum);
        }else{
            System.out.println(B_sum);
        }
        
    } main {
        
        Scanner scanner = new Scanner(System.in);
        String a = scanner.next(); //文字列a
        int A = Integer.parseInt(a); //数字A
        String b = scanner.next(); //文字列b
        int B = Integer.parseInt(b); //数字B
        
        String a_sum = "";
        String b_sum = "";
        
        for(int i=0; i<B; i++){
            a_sum = a_sum +a;
        }
        
        for(int i=0; i<A; i++){
            b_sum = b_sum +b;
        }
        
        int A_sum = Integer.parseInt(a_sum);
        int B_sum = Integer.parseInt(b_sum);
        
        if(A<=B){
            System.out.println(A_sum);
        }else{
            System.out.println(B_sum);
        }
        
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) String a = scanner.next(); a scanner.next() scanner.next scanner int A = Integer.parseInt(a); A Integer.parseInt(a) Integer.parseInt Integer a String b = scanner.next(); b scanner.next() scanner.next scanner int B = Integer.parseInt(b); B Integer.parseInt(b) Integer.parseInt Integer b String a_sum = ""; a_sum "" String b_sum = ""; b_sum "" for(int i=0; i<B; i++){
            a_sum = a_sum +a;
        } int i=0; int i=0; i 0 i<B i B i++ i++ i {
            a_sum = a_sum +a;
        } {
            a_sum = a_sum +a;
        } a_sum = a_sum +a a_sum a_sum +a a_sum a for(int i=0; i<A; i++){
            b_sum = b_sum +b;
        } int i=0; int i=0; i 0 i<A i A i++ i++ i {
            b_sum = b_sum +b;
        } {
            b_sum = b_sum +b;
        } b_sum = b_sum +b b_sum b_sum +b b_sum b int A_sum = Integer.parseInt(a_sum); A_sum Integer.parseInt(a_sum) Integer.parseInt Integer a_sum int B_sum = Integer.parseInt(b_sum); B_sum Integer.parseInt(b_sum) Integer.parseInt Integer b_sum if(A<=B){
            System.out.println(A_sum);
        }else{
            System.out.println(B_sum);
        } A<=B A B {
            System.out.println(A_sum);
        } System.out.println(A_sum) System.out.println System.out System System.out A_sum {
            System.out.println(B_sum);
        } System.out.println(B_sum) System.out.println System.out System System.out B_sum String[] args args public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scanner = new Scanner(System.in);
        String a = scanner.next(); //文字列a
        int A = Integer.parseInt(a); //数字A
        String b = scanner.next(); //文字列b
        int B = Integer.parseInt(b); //数字B
        
        String a_sum = "";
        String b_sum = "";
        
        for(int i=0; i<B; i++){
            a_sum = a_sum +a;
        }
        
        for(int i=0; i<A; i++){
            b_sum = b_sum +b;
        }
        
        int A_sum = Integer.parseInt(a_sum);
        int B_sum = Integer.parseInt(b_sum);
        
        if(A<=B){
            System.out.println(A_sum);
        }else{
            System.out.println(B_sum);
        }
        
    }
} public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scanner = new Scanner(System.in);
        String a = scanner.next(); //文字列a
        int A = Integer.parseInt(a); //数字A
        String b = scanner.next(); //文字列b
        int B = Integer.parseInt(b); //数字B
        
        String a_sum = "";
        String b_sum = "";
        
        for(int i=0; i<B; i++){
            a_sum = a_sum +a;
        }
        
        for(int i=0; i<A; i++){
            b_sum = b_sum +b;
        }
        
        int A_sum = Integer.parseInt(a_sum);
        int B_sum = Integer.parseInt(b_sum);
        
        if(A<=B){
            System.out.println(A_sum);
        }else{
            System.out.println(B_sum);
        }
        
    }
} Main
import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scanner = new Scanner(System.in);
        String a = scanner.next(); //文字列a
        int A = Integer.parseInt(a); //数字A
        String b = scanner.next(); //文字列b
        int B = Integer.parseInt(b); //数字B
        
        String a_sum = "";
        String b_sum = "";
        
        for(int i=0; i<B; i++){
            a_sum = a_sum +a;
        }
        
        for(int i=0; i<A; i++){
            b_sum = b_sum +b;
        }
        
        int A_sum = Integer.parseInt(a_sum);
        int B_sum = Integer.parseInt(b_sum);
        
        if(A<=B){
            System.out.println(A_sum);
        }else{
            System.out.println(B_sum);
        }
        
    }
}
