Drazil is playing a math game with Varda.

Let's define <image> for positive integer x as a product of factorials of its digits. For example, <image>.

First, they choose a decimal number a consisting of n digits that contains at least one digit larger than 1. This number may possibly start with leading zeroes. Then they should find maximum positive number x satisfying following two conditions:

1. x doesn't contain neither digit 0 nor digit 1.

2. <image> = <image>.

Help friends find such number.

Input

The first line contains an integer n (1 ≤ n ≤ 15) — the number of digits in a.

The second line contains n digits of a. There is at least one digit in a that is larger than 1. Number a may possibly contain leading zeroes.

Output

Output a maximum possible integer satisfying the conditions above. There should be no zeroes and ones in this number decimal representation.

Examples

Input

4
1234


Output

33222


Input

3
555


Output

555

Note

In the first case, <image>
//package drazilandfactorial;

import java.util.Arrays;
import java.util.Scanner;

/**
 *
 * @author satenov
 */
public class DrazilAndFactorial {

    /**
     * @param args the command line arguments
     */
    public static int b[] = new int[10];
    
    public static void main(String[] args) {
        // TODO code application logic here
        Scanner in = new Scanner(System.in);
        
        int n = in.nextInt();
        
        int a [] = new int[n];
        
        String input = in.next();
        
        for(int i=0; i< n; i++){
            a[i] = (int)input.charAt(i)-48;
//            System.out.println((int)input.charAt(i)-48);
        }
        String st = "";
        int p[] = new int[10];
        for(int i=0; i< n; i++){
            if (a[i] > 1) {
                res = new int[10];
                max = 0;
                b = new int[10];
                st += Rec(fac(a[i]), 0, "");
                int inc = 0;
                for (int j=2; j<10; j++){
                    if (res[j]>0) {
                        p[j] += res[j];
                        inc++;
                    }
                }
                if (inc == 0){
                    p[a[i]]++;
                }
 
            }
        }

        for (int i=9; i>1; i--)
        {
            for (int j=0; j<p[i]; j++)
                System.out.print(i);
        }
        System.out.println();
    }
    
    public static int max = 0;
    public static int res[] = new int[10];
    
    public static String Rec(int x, int len, String s){
        //System.out.println(x + "   " + len+ " " + s);
        if (x == 1) {
            if (len > max){
                max = len;
                res = Arrays.copyOf(b, 10);
            }
            return s;
        }
        if (x % 2 == 0){
            b[2]++;
            String y = Rec(x/2, len+1, s+"2");
            b[2]--;
        }
        if (x % 6 == 0){
            b[3]++;
            String y = Rec(x/6, len+1, s+"3");
            b[3]--;
        }
        if (x % 24 == 0){
            b[4]++;
            String y = Rec(x/24, len+1, s+"4");
            b[4]--;
        }
        if (x % 120 == 0){
            b[5]++;
            String y = Rec(x/120, len+1, s+"5");
            b[5]--;
        }
        if (x % 720 == 0){
            b[6]++;
            String y = Rec(x/720, len+1, s+"6");
            b[6]--;
        }
        if (x % 5040 == 0){
            b[7]++;
            String y = Rec(x/5040, len+1, s+"7");
            b[7]--;
        }
        if (x % 40320 == 0){
            b[8]++;
            String y = Rec(x/40320, len+1, s+"8");
            b[8]--;
        }
        if (x % 362880 == 0){
            b[9]++;
            String y = Rec(x/362880, len+1, s+"9");
            b[9]--;
        }
        return s;
    }
    
    
    public static int fac(int a){
        int res = 1;
        for (int i=1; i <= a; i++)
            res = res * i;
        return res;
    }
}