#include <bits/stdc++.h>
using namespace std;
template <typename T>
void showSTL(T H);
template <typename T, typename V>
void showSTL(pair<T, V> H);
template <typename T>
void showSTL(priority_queue<T> H);
template <typename T>
void showSTL(stack<T> H);
template <typename T, typename V>
void showSTL(map<T, V> H);
template <typename T, typename V>
void showSTL(multimap<T, V> H);
template <typename T>
void showSTL(vector<T> H);
template <typename T>
void showSTL(set<T> H);
template <typename T>
void showSTL(multiset<T> H);
template <typename T>
void showSTL(list<T> H);
void showSTL(char *H);
template <typename T>
void showSTL(deque<T> H);
template <typename T>
void showSTL(queue<T> H);
template <typename T>
void showSTL(T H) {
  stringstream ss;
  ss << H;
  cerr << ss.str();
}
template <typename T, typename V>
void showSTL(pair<T, V> H) {
  cerr << "(";
  showSTL(H.first);
  cerr << "=>";
  showSTL(H.second);
  cerr << ")";
}
template <typename T>
void showSTL(priority_queue<T> H) {
  cerr << '\n';
  while (!H.empty()) {
    cerr << H.top() << '\n';
    H.pop();
  }
  cerr << '\n';
}
template <typename T>
void showSTL(stack<T> H) {
  cerr << '\n';
  while (!H.empty()) {
    cerr << H.top() << '\n';
    H.pop();
  }
}
template <typename T, typename V>
void showSTL(map<T, V> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << " ";
  }
  cerr << "]";
}
template <typename T, typename V>
void showSTL(multimap<T, V> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << " ";
  }
  cerr << "]";
}
template <typename T>
void showSTL(vector<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
template <typename T>
void showSTL(set<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
template <typename T>
void showSTL(multiset<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
template <typename T>
void showSTL(list<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
void showSTL(char *H) {
  for (int i = 0; i < strlen(H); i++) {
    showSTL(H[i]);
  };
}
template <typename T>
void showSTL(deque<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
template <typename T>
void showSTL(queue<T> H) {
  cerr << "[ ";
  while (!H.empty()) {
    showSTL(H.front());
    cerr << ' ';
    H.pop();
  }
  cerr << "]";
}
vector<string> vec_spltr(string s) {
  s += ',';
  vector<string> res;
  while (!s.empty())
    res.push_back(s.substr(0, s.find(','))), s = s.substr(s.find(',') + 1);
  return res;
}
void dbg_out(vector<string> __attribute__((unused)) args,
             __attribute__((unused)) int idx,
             __attribute__((unused)) int LINE_NUM) {
  cerr << '\n';
}
template <typename Head, typename... Tail>
void dbg_out(vector<string> args, int idx, int LINE_NUM, Head H, Tail... T) {
  if (idx > 0)
    cerr << ", ";
  else
    cerr << "Line(" << LINE_NUM << "):";
  cerr << " " << args[idx] << " = ";
  showSTL(H);
  dbg_out(args, idx + 1, LINE_NUM, T...);
}
int main() {
  long long n;
  cin >> n;
  string s;
  cin >> s;
  int ss[] = {0, 1, 2, 3, 322, 5, 53, 7, 7222, 7332};
  string ans = "";
  for (int(i) = 0; (i) < (n); (i)++) {
    if (s[i] == '1' || s[i] == '0') continue;
    ans += to_string(ss[s[i] - '0']);
  }
  sort(ans.rbegin(), ans.rend());
  cout << ans << '\n';
  return 0;
}

### Prompt

Please formulate a CPP solution to the following problem:

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;
template <typename T>
void showSTL(T H);
template <typename T, typename V>
void showSTL(pair<T, V> H);
template <typename T>
void showSTL(priority_queue<T> H);
template <typename T>
void showSTL(stack<T> H);
template <typename T, typename V>
void showSTL(map<T, V> H);
template <typename T, typename V>
void showSTL(multimap<T, V> H);
template <typename T>
void showSTL(vector<T> H);
template <typename T>
void showSTL(set<T> H);
template <typename T>
void showSTL(multiset<T> H);
template <typename T>
void showSTL(list<T> H);
void showSTL(char *H);
template <typename T>
void showSTL(deque<T> H);
template <typename T>
void showSTL(queue<T> H);
template <typename T>
void showSTL(T H) {
  stringstream ss;
  ss << H;
  cerr << ss.str();
}
template <typename T, typename V>
void showSTL(pair<T, V> H) {
  cerr << "(";
  showSTL(H.first);
  cerr << "=>";
  showSTL(H.second);
  cerr << ")";
}
template <typename T>
void showSTL(priority_queue<T> H) {
  cerr << '\n';
  while (!H.empty()) {
    cerr << H.top() << '\n';
    H.pop();
  }
  cerr << '\n';
}
template <typename T>
void showSTL(stack<T> H) {
  cerr << '\n';
  while (!H.empty()) {
    cerr << H.top() << '\n';
    H.pop();
  }
}
template <typename T, typename V>
void showSTL(map<T, V> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << " ";
  }
  cerr << "]";
}
template <typename T, typename V>
void showSTL(multimap<T, V> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << " ";
  }
  cerr << "]";
}
template <typename T>
void showSTL(vector<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
template <typename T>
void showSTL(set<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
template <typename T>
void showSTL(multiset<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
template <typename T>
void showSTL(list<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
void showSTL(char *H) {
  for (int i = 0; i < strlen(H); i++) {
    showSTL(H[i]);
  };
}
template <typename T>
void showSTL(deque<T> H) {
  cerr << "[ ";
  for (auto val : H) {
    showSTL(val);
    cerr << ' ';
  }
  cerr << "]";
}
template <typename T>
void showSTL(queue<T> H) {
  cerr << "[ ";
  while (!H.empty()) {
    showSTL(H.front());
    cerr << ' ';
    H.pop();
  }
  cerr << "]";
}
vector<string> vec_spltr(string s) {
  s += ',';
  vector<string> res;
  while (!s.empty())
    res.push_back(s.substr(0, s.find(','))), s = s.substr(s.find(',') + 1);
  return res;
}
void dbg_out(vector<string> __attribute__((unused)) args,
             __attribute__((unused)) int idx,
             __attribute__((unused)) int LINE_NUM) {
  cerr << '\n';
}
template <typename Head, typename... Tail>
void dbg_out(vector<string> args, int idx, int LINE_NUM, Head H, Tail... T) {
  if (idx > 0)
    cerr << ", ";
  else
    cerr << "Line(" << LINE_NUM << "):";
  cerr << " " << args[idx] << " = ";
  showSTL(H);
  dbg_out(args, idx + 1, LINE_NUM, T...);
}
int main() {
  long long n;
  cin >> n;
  string s;
  cin >> s;
  int ss[] = {0, 1, 2, 3, 322, 5, 53, 7, 7222, 7332};
  string ans = "";
  for (int(i) = 0; (i) < (n); (i)++) {
    if (s[i] == '1' || s[i] == '0') continue;
    ans += to_string(ss[s[i] - '0']);
  }
  sort(ans.rbegin(), ans.rend());
  cout << ans << '\n';
  return 0;
}

```