#include <bits/stdc++.h>
using namespace std;
bool isPrime(int x) {
  if (x < 2) return false;
  for (int i = 2; i <= sqrt(x); i++)
    if (x % i == 0) return false;
  return true;
}
int main() {
  string s;
  cin >> s;
  int al[26] = {0};
  char ans[1005], c;
  bool u[1005] = {false};
  int l = s.size();
  int mx = 0, cnt = 0;
  for (int i = 0; i < l; i++) al[s[i] - 'a']++;
  for (int i = 0; i < 26; i++)
    if (al[i] > mx) {
      mx = al[i];
      c = i + 'a';
    }
  for (int i = l / 2 + 1; i <= l; i++)
    if (isPrime(i)) {
      cnt++;
      u[i - 1] = true;
    }
  cnt = l - cnt - 1;
  if (mx < cnt) {
    cout << "NO" << endl;
    return 0;
  }
  cout << "YES" << endl;
  for (int i = 1; i < l; i++)
    if (!u[i]) {
      ans[i] = c;
      al[c - 'a']--;
    }
  for (int i = 0; i < l; i++)
    if (u[i] || i == 0)
      for (int j = 0; j < 26; j++)
        if (al[j] != 0) {
          ans[i] = j + 'a';
          al[j]--;
          break;
        }
  for (int i = 0; i < l; i++) cout << ans[i];
}
