#include <bits/stdc++.h>
using namespace std;
const long long mod = 1000000007L;
const int SIZE = 800010;
int cnt[300];
char ans[SIZE];
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout << fixed << setprecision(15);
  int n;
  cin >> n;
  string s;
  cin >> s;
  for (int i = 0; i < n; i++) {
    cnt[s[i]]++;
  }
  int odd = 0, even = 0;
  for (int i = 0; i < 300; i++) {
    if (cnt[i] % 2 != 0)
      odd++;
    else
      even++;
  }
  int a = n;
  for (int i = 1; i <= n; i++) {
    int x = n / i;
    if (x * i != n) continue;
    bool flag = 0;
    int o = odd;
    int e = even;
    if (x % 2) {
      if (o > i) flag = 1;
    } else {
      if (o) flag = 1;
    }
    if (!flag) {
      a = i;
      break;
    }
  }
  cout << a << endl;
  int x = n / a;
  if (x % 2) {
    for (int i = 0; i < a; i++) {
      int mid = x / 2;
      int j = 0;
      int idx = 0;
      while (j <= mid) {
        for (int k = 0; k < 300 && j < mid; k++) {
          while (j < mid && cnt[k] >= 2) {
            cnt[k] -= 2;
            char ch = (char)k;
            j++;
            ans[idx] = ch;
            ans[x - 1 - idx] = ch;
            idx++;
          }
        }
        char ch;
        bool flag = 0;
        for (int k = 0; k < 300; k++) {
          if (cnt[k] % 2 != 0) {
            flag = 1;
            ch = (char)k;
            cnt[k] -= 1;
            j++;
            break;
          }
        }
        if (!flag) {
          for (int k = 0; k < 300; k++) {
            if (cnt[k] > 0) {
              cnt[k] -= 1;
              ch = (char)k;
              j++;
              break;
            }
          }
        }
        ans[idx] = ch;
        idx++;
      }
      cout << ans << " ";
    }
    cout << endl;
  } else {
    for (int i = 0; i < a; i++) {
      int mid = x / 2;
      int j = 0;
      int idx = 0;
      while (j < mid) {
        for (int k = 0; k < 300 && j < mid; k++) {
          while (j < mid && cnt[k] >= 2) {
            cnt[k] -= 2;
            char ch = (char)k;
            j++;
            ans[idx] = ch;
            ans[x - 1 - idx] = ch;
            idx++;
          }
        }
      }
      cout << ans << " ";
    }
    cout << endl;
  }
  return 0;
}
