#include <bits/stdc++.h>
using namespace std;
const int maxx = 1e5 + 10;
vector<string> s(maxx + 5);
int last, freq;
vector<char> vow{'a', 'e', 'i', 'o', 'u'};
vector<pair<int, int> > g[30];
vector<pair<int, int> > pp, ex, qq, add;
void calco(int id) {
  string x = s[id];
  for (int i = 0; i < x.size(); i++) {
    char c = x[i];
    if (c == 'a' || c == 'e' || c == 'i' || c == 'o' || c == 'u') {
      freq++;
      last = c - '0' - 48;
    }
  }
}
int main() {
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) {
    freq = 0;
    string x;
    cin >> x;
    s[i] = x;
    calco(i);
    g[last].push_back({freq, i});
  }
  for (auto c : vow) {
    int idx = c - '0' - 48;
    sort(g[idx].begin(), g[idx].end());
    int len = g[idx].size(), k = 1;
    if (len == 0) {
      continue;
    }
    while (k < len) {
      pair<int, int> a = g[idx][k], b = g[idx][k - 1];
      if (a.first == b.first) {
        pp.push_back({a.second, b.second});
        k += 2;
      } else {
        ex.push_back({b});
        k++;
      }
    }
    if (k == len) {
      ex.push_back(g[idx][len - 1]);
    }
  }
  sort(ex.begin(), ex.end());
  int len = ex.size(), k = 1;
  while (k < len) {
    pair<int, int> a = ex[k], b = ex[k - 1];
    if (a.first == b.first) {
      qq.push_back({a.second, b.second});
      k += 2;
    } else {
      add.push_back({b});
      k++;
    }
  }
  if (k == len) {
    add.push_back(ex[len - 1]);
  }
  int idx = 0;
  if (pp.size() > qq.size()) {
    idx = pp.size() + qq.size();
    idx = idx >> 1;
    int kk = idx - qq.size();
    for (int i = 0; i < kk; i++) {
      pair<int, int> a = pp[i];
      qq.push_back(a);
    }
  } else {
    idx = pp.size();
  }
  int x = pp.size(), y = qq.size();
  cout << idx << endl;
  while (idx--) {
    x--;
    y--;
    pair<int, int> a = pp[x], b = qq[y];
    cout << s[b.first] << " " << s[a.first] << endl;
    cout << s[b.second] << " " << s[a.second] << endl;
  }
  return 0;
}
