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.math.BigInteger;

public class Main{
    final boolean isFileIO =  false;
    BufferedReader in;
    PrintWriter out;
    StringTokenizer st = new StringTokenizer("");
    String delim = " ";

    public static void main(String[] args) throws IOException {
        Main m = new Main();
        m.initIO();
        m.solve();
        m.in.close();
        m.out.close();
    }

    public void initIO() throws IOException {
        if(!isFileIO) {
            in = new BufferedReader(new InputStreamReader(System.in));
            out = new PrintWriter(System.out);
        } else {
            in = new BufferedReader(new FileReader("input.txt"));
            out = new PrintWriter("output.txt");
        }
    }

    String nt() throws IOException {
        if(!st.hasMoreTokens()) {
            st = new StringTokenizer(in.readLine());
        }
        return st.nextToken(delim);
    }

    String rl() throws IOException {
        return in.readLine();
    }

    int ni() throws IOException {
        return Integer.parseInt(nt());
    }

    long nl() throws IOException {
        return Long.parseLong(nt());
    }

    double nd() throws IOException {
        return Double.parseDouble(nt());
    }

    class Pair {
        public int x, y;
        public Pair(int x, int y) {
            this.x = x;
            this.y = y;
        }
    }

    public void solve() throws IOException {
        int n = ni();
        int[] primes = {2, 3, 5, 7};
        String s = rl();
        HashMap<Integer, Integer> hs = new HashMap<Integer, Integer>();
        for(int i = 0; i < 4; i++) {
            hs.put(primes[i], 0);
        }
        for(int i = 0; i < n; i++) {
            int source = Character.getNumericValue(s.charAt(i));
            if(source <= 1) {
                continue;
            }
            for(int j = 2; j <= source; j++) {
                int m = j;
                for(int z = 0; z < 4; z++) {
                    while(m % primes[z] == 0) {
                        hs.put(primes[z], hs.get(primes[z]) + 1);
                        m /= primes[z];
                    }
                }
            }
        }
        for(int i = 3; i >= 0; i--) {
            int cnt = hs.get(primes[i]);
            HashMap<Integer, Integer> temp = new HashMap<Integer, Integer>();
            for(int j = 0; j < 4; j++) {
                temp.put(primes[j], 0);
            }
            for(int j = 2; j < primes[i]; j++) {
                int m = j;
                for(int z = 0; z < 4; z++) {
                    while(m % primes[z] == 0) {
                        temp.put(primes[z], temp.get(primes[z]) + 1);
                        m /= primes[z];
                    }
                }
            }
            for(int j = 0; j < 4; j++) {
                hs.put(primes[j], hs.get(primes[j]) - temp.get(primes[j]) * cnt);
            }
            for(int j = 0; j < cnt; j++) {
                out.print(primes[i]);
            }
        }
    }
}

class Utils {

    public static long binpow(long a, long exp, long mod) {
        if(exp == 0) {
            return 1;
        }
        if(exp % 2 == 0) {
            long temp = binpow(a, exp / 2, mod);
            return (temp * temp) % mod;
        } else {
            return (binpow(a, exp - 1, mod) * a) % mod;
        }
    }

    public static long inv(long a, long mod) {
        return binpow(a, mod - 2, mod);
    }

    public static long addmod(long a, long b, long mod) {
        return ((a + b) % mod + mod) % mod;
    }

    public static long gcd(long a, long b) {
        if(b == 0)
            return a;
        return gcd(b, a % b);
    }

    //mul must be < 10^18
    public static long mulmod(long a, long b, long mod) {
        return (a * b + (((a * b) / mod) + 1) * mod) % mod;
    }
}