#include <bits/stdc++.h>
using namespace std;
int times[26];
bool prime[1005];
int main(int argc, char const *argv[]) {
  string s;
  cin >> s;
  int n = s.length();
  for (int i = 0; i < n; ++i) times[s[i] - 'a']++;
  int maxt = max_element(times, times + 26) - times;
  for (int i = 0; i < 1005; i++) prime[i] = true;
  for (int i = 2; i * i < 1005; i++)
    if (prime[i])
      for (int j = i * i; j < 1005; j += i) prime[j] = false;
  prime[1] = true;
  for (int i = 2; i + i <= n; i++) prime[i] = false;
  for (int i = 1; i <= n; i++)
    if (!prime[i]) {
      if (times[maxt] == 0) {
        cout << "NO";
        return 0;
      }
      s[i - 1] = maxt + 'a';
      times[maxt]--;
    }
  maxt = 0;
  for (int i = 1; i <= n; i++)
    if (prime[i]) {
      while (times[maxt] == 0) maxt++;
      s[i - 1] = maxt + 'a';
      times[maxt]--;
    }
  cout << "YES" << endl << s;
  return 0;
}
