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 sys
from collections import Counter
from math import factorial

input = sys.stdin
output = sys.stdout

# input = open('input.txt')


def read_int():
    return [int(x) for x in input.readline().rstrip().split()]


def F(mas):
    ans = 1
    for x in mas:
        ans *= factorial(x)
    return ans

d = dict()
def solve(mult, min_value):
    # print mult
    if mult < 2:
        return None
    if mult not in d:
        answer = None
        for digit in xrange(min_value, 10):
            _f = factorial(digit)
            if _f > mult:
                break
            if mult % _f == 0:
                if mult == _f:
                    _answer = []
                else:
                    _answer = solve(mult / _f, digit)
                if _answer is not None:
                    _answer.append(digit)
                    _answer.sort()
                    _answer.reverse()
                    if answer is None \
                            or len(_answer) > len(answer) \
                            or (len(_answer) == len(answer) and _answer > answer):
                        answer = _answer
        d[mult] = answer
        # print 'd[%d] = %s' % (mult, str(answer))
        # print str(d)
    result = d[mult]
    if result is not None:
        result = result[:]
    return result


[n] = read_int()
a = input.readline().rstrip()
a = [int(x) for x in a]
fac = F(a)
answer = solve(fac, 2)
answer = ''.join(str(x) for x in answer)
output.write('%s\n' % answer)

# output.write('%d\n' % answer)






