#include <bits/stdc++.h>
using namespace std;
const int N = 1e6 + 10;
vector<pair<int, int> > ho, qi;
int d[130];
int vis[N][6];
string s[N];
int main() {
  d['a'] = 1, d['e'] = 2, d['i'] = 3, d['o'] = 4, d['u'] = 5;
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    cin >> s[i];
    int len = s[i].length(), tot = 0, la;
    for (int j = 0; j < len; j++)
      if (d[s[i][j]]) tot++, la = d[s[i][j]];
    if (vis[tot][la]) {
      ho.push_back(make_pair(vis[tot][la], i));
      vis[tot][la] = 0;
    } else
      vis[tot][la] = i;
  }
  for (int i = 1; i <= n; i++) {
    int la = 0;
    for (int j = 1; j <= 5; j++) {
      if (vis[i][j]) {
        if (la) {
          qi.push_back(make_pair(vis[i][j], la));
          la = 0;
        } else
          la = vis[i][j];
      }
    }
  }
  while (qi.size() < ho.size()) {
    qi.push_back(ho.back());
    ho.pop_back();
  }
  printf("%d\n", ho.size());
  for (int i = 0; i < ho.size(); i++) {
    cout << s[qi[i].first] << " " << s[ho[i].first] << endl
         << s[qi[i].second] << " " << s[ho[i].second] << endl;
  }
  return 0;
}
