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>
import java.io.*;
import java.util.*;
import java.text.*;
import java.math.*;
import java.util.regex.*;

public class Solution {

    public boolean isPrime(int n){
        if(n < 2) return false;
        else if(n == 2) return true;
        else if(n%2 == 0) return false;
        for (int i = 1; 4*i*i+4*i+1 <= n; i++) {
            if(n%(i*2+1)==0){
                return false;
            }
        }
        return true;
    }

    public int factorial(int n){
        if(n < 2) return 1;
        if(n == 2) return 2;
        int fact = n;
        while(--n >= 2){
            fact *= n;
        }
        return fact;
    }

    public List<Integer> findMultipliers(int n) {
        List<Integer> multipliers = new ArrayList<>();
        if (n < 2) return multipliers;
        else if(n%2==0){
            int m = n;
            int c = 0;
            while(m%2==0){
                m/=2;
                c++;
            }
            if(m==1){
                for (int i = 0; i < c; i++) {
                    multipliers.add(2);
                }
                return multipliers;
            }
        }
        int i = 3;
        long f = factorial(i);
        while(f<n && n%f!=0){
            f = factorial(++i);
        }
        if(n==f){
            multipliers.add(i);
        }else if(n%f==0){
            multipliers.add(i);
            multipliers.addAll(findMultipliers((int)(n/f)));
        }
        return multipliers;
    }

    public List<Integer> findFactors(int n){
        List<Integer> factors = new ArrayList<>();
        if(n<2){
            return factors;
        }
        int mult = 1;
        while(!isPrime(n)){
            mult*=n;
            n--;
        }
        factors.addAll(findMultipliers(mult));
        factors.add(n);
        return factors;
    }

    public void run(){
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        String a = in.next();
        List<Integer>[] digitFactors = new List[10];
        for (int i = 0; i < 10; i++) {
            digitFactors[i] = new ArrayList<>();
            digitFactors[i].addAll(findFactors(i));
        }
        List<Integer> digits = new ArrayList<>();
        int digit;
        for (int i = 0; i < n; i++) {
            digit = (int)(a.charAt(i) - '0');
            if(digit < 2) continue;
            digits.addAll(digitFactors[digit]);
        }
        Collections.sort(digits, Collections.reverseOrder());

        for(Integer i : digits){
            System.out.print(i);
        }
        System.out.println();
    }

    public static void main(String[] args) {
        Solution sol = new Solution();
        sol.run();
    }
}