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>
# -*- coding: utf-8 -*-
import sys
import heapq
from collections import defaultdict
from collections import OrderedDict
import copy
from collections import deque


class Solver(object):

    def run(self):
        n = read(int)
        a = map(int, list(read(str)))

        def addElem(elem, i, isAdd):

            func = lambda i: i
            if not isAdd:
                func = lambda i: -i

            if i in [0, 1]:
                pass
            elif i == 2:
                elem[2] += func(1)
            elif i == 3:
                elem[3] += func(1)
            elif i == 4:
                elem[2] += func(2)
            elif i == 5:
                elem[5] += func(1)
            elif i == 6:
                elem[2] += func(1)
                elem[3] += func(1)
            elif i == 7:
                elem[7] += func(1)
            elif i == 8:
                elem[2] += func(3)
            elif i == 9:
                elem[3] += func(2)

        # 0..loop
        def addElemLoop(elem, isAdd, loop):
            for t in xrange(loop+1):
                addElem(elem, t, isAdd)
            return elem

        elems = defaultdict(int)
        for i in a:
            addElemLoop(elems, True, i)

        res = []
        keys = sorted(elems.keys(), reverse=True)
        for k in keys:
            for i in xrange(elems[k]):
                res.append(k)
                addElemLoop(elems, False, k)

        print("".join(map(str,res)))





####################################
# ここからは見ちゃダメ！

def read(foo):
    return foo(raw_input())
def readarray(foo):
    return [foo(x) for x in raw_input().split()]
def dbg(a):
    sys.stderr.write(str(a))
def dbgln(a):
    sys.stderr.write(str(a) + "\n")
# https://gist.github.com/kachayev/5910538
def topological(graph):
    GRAY, BLACK = 0, 1
    order, enter, state = deque(), set(graph), {}
    def dfs(node):
        state[node] = GRAY
        for k in graph.get(node, ()):
            sk = state.get(k, None)
            if sk == GRAY: raise ValueError("cycle")
            if sk == BLACK: continue
            enter.discard(k)
            dfs(k)
        order.appendleft(node)
        state[node] = BLACK
    while enter: dfs(enter.pop())
    return order
# l1 to l2 -> line
# ls1 to ls2 -> line segment
def lineIntersect( l1, l2, ls1, ls2 ):
    l1x, l1y = l1
    l2x, l2y = l2
    ls1x, ls1y = ls1
    ls2x, ls2y = ls2
    if (((l1x - l2x) * (ls1y - l1y) + (l1y - l2y) * (l1x - ls1x)) *
        ((l1x - l2x) * (ls2y - l1y) + (l1y - l2y) * (l1x - ls2x)) > 0):
        return False
    return True
# p1 to p2 -> line segment
# p3 to p4 -> line segemnt
def intersect( p1, p2, p3, p4 ):
    if lineIntersect(p1, p2, p3, p4) and lineIntersect(p3, p4, p1, p2):
        return True
    return False

if __name__ == '__main__':
    Solver().run()
