#include <bits/stdc++.h>
using namespace std;
const int maxm = 100001;
long long m = 1e9 + 7;
vector<vector<int> > adj;
vector<int> h;
vector<int> sz;
vector<int> in;
long long fe(long long base, long long exp) {
  long long res = 1;
  while (exp > 0) {
    if (exp % 2 == 1) res = (res * base) % 1000000007;
    ;
    base = (base * base) % 1000000007;
    ;
    exp /= 2;
  }
  return res % 1000000007;
  ;
}
void dfs_h_sz(int cur, int par) {
  h[cur] = h[par] + 1;
  sz[cur]++;
  for (const auto &v : adj[cur]) {
    if (v == par) continue;
    dfs_h_sz(v, cur);
    sz[cur] += sz[v];
  }
}
void buildGraph(int n, int m) {
  adj = vector<vector<int> >(n + 1);
  h = vector<int>(n + 1);
  sz = vector<int>(n + 1);
  in = vector<int>(n + 1);
  for (int i = 0; i < m; i++) {
    int a, b;
    cin >> a >> b;
    adj[a].push_back(b);
    adj[b].push_back(a);
  }
  dfs_h_sz(1, 0);
}
struct cmp {
  bool operator()(const pair<int, int> &a, const pair<int, int> &b) {
    return a.first < b.first;
  }
};
long long add(long long a, long long b) { return ((a % m) + (b % m)) % m; }
long long mul(long long a, long long b) { return ((a % m) * (b % m)) % m; }
long long sub(long long a, long long b) { return ((a % m) - (b % m) + m) % m; }
void solve() {
  int n;
  cin >> n;
  map<char, string> mc = {{'2', "2"},    {'3', "3"},   {'4', "223"},
                          {'5', "5"},    {'6', "35"},  {'7', "7"},
                          {'8', "2227"}, {'9', "2337"}};
  string str;
  cin >> str;
  string in;
  for (int i = 0; i < str.size(); i++) {
    if (str[i] != '0' && str[i] != '1') {
      in += mc[str[i]];
    }
  }
  sort(in.begin(), in.end());
  reverse(in.begin(), in.end());
  cout << in << "\n";
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(NULL);
  ;
  int test;
  test = 1;
  while (test--) {
    solve();
  }
  return 0;
}

### Prompt

Construct a CPP code solution to the problem outlined:

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>

### Response

```cpp
#include <bits/stdc++.h>
using namespace std;
const int maxm = 100001;
long long m = 1e9 + 7;
vector<vector<int> > adj;
vector<int> h;
vector<int> sz;
vector<int> in;
long long fe(long long base, long long exp) {
  long long res = 1;
  while (exp > 0) {
    if (exp % 2 == 1) res = (res * base) % 1000000007;
    ;
    base = (base * base) % 1000000007;
    ;
    exp /= 2;
  }
  return res % 1000000007;
  ;
}
void dfs_h_sz(int cur, int par) {
  h[cur] = h[par] + 1;
  sz[cur]++;
  for (const auto &v : adj[cur]) {
    if (v == par) continue;
    dfs_h_sz(v, cur);
    sz[cur] += sz[v];
  }
}
void buildGraph(int n, int m) {
  adj = vector<vector<int> >(n + 1);
  h = vector<int>(n + 1);
  sz = vector<int>(n + 1);
  in = vector<int>(n + 1);
  for (int i = 0; i < m; i++) {
    int a, b;
    cin >> a >> b;
    adj[a].push_back(b);
    adj[b].push_back(a);
  }
  dfs_h_sz(1, 0);
}
struct cmp {
  bool operator()(const pair<int, int> &a, const pair<int, int> &b) {
    return a.first < b.first;
  }
};
long long add(long long a, long long b) { return ((a % m) + (b % m)) % m; }
long long mul(long long a, long long b) { return ((a % m) * (b % m)) % m; }
long long sub(long long a, long long b) { return ((a % m) - (b % m) + m) % m; }
void solve() {
  int n;
  cin >> n;
  map<char, string> mc = {{'2', "2"},    {'3', "3"},   {'4', "223"},
                          {'5', "5"},    {'6', "35"},  {'7', "7"},
                          {'8', "2227"}, {'9', "2337"}};
  string str;
  cin >> str;
  string in;
  for (int i = 0; i < str.size(); i++) {
    if (str[i] != '0' && str[i] != '1') {
      in += mc[str[i]];
    }
  }
  sort(in.begin(), in.end());
  reverse(in.begin(), in.end());
  cout << in << "\n";
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(NULL);
  ;
  int test;
  test = 1;
  while (test--) {
    solve();
  }
  return 0;
}

```