Drazil is playing a math game with Varda.

Let's define <img align="middle" class="tex-formula" src="https://espresso.codeforces.com/7020b94c48be2ee5b8eeca05f379c8911bb0e7c4.png" style="max-width: 100.0%;max-height: 100.0%;"/> for positive integer *x* as a product of factorials of its digits. For example, <img align="middle" class="tex-formula" src="https://espresso.codeforces.com/6784d861d9a724d0aeddefcb00b7d0c3442ae586.png" style="max-width: 100.0%;max-height: 100.0%;"/>.

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. <img align="middle" class="tex-formula" src="https://espresso.codeforces.com/7020b94c48be2ee5b8eeca05f379c8911bb0e7c4.png" style="max-width: 100.0%;max-height: 100.0%;"/> = <img align="middle" class="tex-formula" src="https://espresso.codeforces.com/aa57e017a6c74d06b0a54bc47e3f6990e5af38c1.png" style="max-width: 100.0%;max-height: 100.0%;"/>.

Help friends find such number.
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.
import sys
import re
from math import gcd, factorial as fact, comb, hypot, atan2, pi,ceil,sqrt
from heapq import *
from random import *
from itertools import *
from functools import *
from bisect import *
from collections import *
import threading

threading.stack_size(2**23)

sys.setrecursionlimit(5*10**4+10)

# input = sys.stdin.readline
def read(fn=int):
	return map(fn,input().split())

# toks = (tok for tok in sys.stdin.read().split())
# def rd(fn=int): return fn(next(toks))
# def rdn(n,fn=int): return (rd(fn) for _ in range(n))

def mul(a,b):
	c = [[0 for j in range(len(b[0]))] for i in range(len(a))]
	for i in range(len(a)):
		for j in range(len(b[0])):
			for k in range(len(b)):
				c[i][j] += a[i][k]*b[k][j]
	return c

def power(x,y):
	n = len(x)
	res = [[1 if i==j else 0 for j in range(n)] for i in range(n)]
	while y:
		if y % 2: res = mul(res,x)
		x = mul(x,x)
		y //= 2
	return res	

mod=998244353

def sieve(n,primes):
	n = int(n)
	isp = [True] * (n+1)
	for i in range(2,n+1):
		if isp[i]:
			primes += [i]
			for j in range(i*i,n+1,i):
				isp[j] = False
	return isp

# s,p,t = read()
# P = [*read()]
# sP = {*P}

# adj = [set() for _ in range(2*n)]
# for _ in range(t):
# 	s1,c,s2 = input().split()
# 	s1,s2 = map(int,(s1-1.s2-1))
# 	adj[s1].add(s2)
# 	if s2 

# q = deque([(0,0)])
# first = True
# while q:
# 	d,v = q.popleft()
# 	v = -v
# 	if v == end:
# 		if not first:
# 			print(d)
# 			break
# 		first = False

# 	for vv in adj[v]:
# 		q.append((d+1,-vv))
# else:
# 	print(-1)

# for _ in range(int(input())):
n,=read()
v=input()
f=[1]
for i in range(20):f+=[f[-1]*(i+1)]
x = 1
for c in v:
	x *= f[int(c)]
# print(x)
a = ""
for p in [7,5,3,2]:
	while not x % p:
		print(p,end='')
		x //= f[p]
print()
