#include <bits/stdc++.h>
using namespace std;
vector<int> V;
int n, used[30];
string s;
int is_prime(int num) {
  for (int i = 2; i * i <= num; i++)
    if (num % i == 0) return 0;
  return 1;
}
void init() {
  cin >> s;
  n = s.size();
  if (n <= 3) {
    cout << "YES\n" << s << endl;
    return;
  }
  for (int i = 2; i <= n / 2; i++)
    if (is_prime(i)) V.push_back(i);
  for (int i = 0; i <= n - 1; i++) used[s[i] - 'a']++;
  int mpty = 1, myst = n - 1;
  for (int i = n / 2 + 1; i <= n; i++)
    if (is_prime(i)) {
      myst--;
      mpty++;
    }
  int sol = 0;
  char letter;
  for (int i = 0; i <= 25; i++)
    if (used[i] >= myst) {
      letter = i + 'a';
      sol = 1;
      break;
    }
  if (!sol) {
    cout << "NO\n";
    return;
  }
  string Sol = "";
  Sol.resize(n + 10);
  for (int i = 0; i <= n + 9; i++) Sol[i] = ' ';
  for (int i = 1; i <= n; i++)
    for (int j = 0; j <= V.size() - 1; j++)
      if (i % V[j] == 0) {
        Sol[i] = letter;
        used[letter - 'a']--;
        break;
      }
  for (int i = 1; i <= n; i++)
    if (Sol[i] == ' ') {
      for (int j = 0; j <= 25; j++)
        if (used[j]) {
          Sol[i] = 'a' + j;
          used[j]--;
          break;
        }
    }
  cout << "YES\n";
  for (int i = 1; i <= n; i++) cout << Sol[i];
  cout << endl;
}
int main() {
  init();
  return 0;
}
