#include <bits/stdc++.h>
using namespace std;
const int MOD = 1e9 + 7;
const long long INF = 3 * 1e9 + 7;
const int base = 1e9;
const int MAX = 2 * 1e6;
const double EPS = 1e-9;
const double PI = acos(-1.);
const long long O = pow(2ll, 32) - 1;
char vowels[5] = {'a', 'e', 'o', 'i', 'u'};
bool is(char x) {
  for (int i = (0); i < (5); ++i) {
    if (x == vowels[i]) return true;
  }
  return false;
}
int main() {
  int n;
  scanf("%d", &n);
  map<pair<char, int>, vector<string>> foo;
  vector<pair<string, string>> res1, res2;
  vector<vector<string>> v(MAX);
  int mx = 0;
  for (int i = (0); i < (n); ++i) {
    string s;
    cin >> s;
    int cnt = 0;
    char last;
    for (int j = (0); j < ((int)s.size()); ++j) {
      if (is(s[j])) {
        cnt++;
        last = s[j];
      }
    }
    foo[{last, cnt}].push_back(s);
    mx = max(mx, cnt);
  }
  for (int i = (1); i < (mx + 1); ++i) {
    for (int j = (0); j < (5); ++j) {
      pair<char, int> p = {vowels[j], i};
      int cur = 0;
      while (cur + 1 < (int)foo[p].size()) {
        res2.push_back({foo[p][cur], foo[p][cur + 1]});
        cur += 2;
      }
      if (cur < (int)foo[p].size()) v[i].push_back(foo[p][cur]);
    }
  }
  for (int i = (0); i < (mx + 1); ++i) {
    int cur = 0;
    while (cur + 1 < (int)v[i].size()) {
      res1.push_back({v[i][cur], v[i][cur + 1]});
      cur += 2;
    }
  }
  int m = min((int)res1.size(), (int)res2.size()) +
          max(0, ((int)res2.size() - (int)res1.size()) / 2);
  cout << m << endl;
  for (int i = (0); i < (min((int)res1.size(), (int)res2.size())); ++i) {
    cout << res1[i].first << ' ' << res2[i].first << endl
         << res1[i].second << ' ' << res2[i].second << endl;
  }
  for (int i = (int)res1.size(); i < (int)res2.size(); i += 2) {
    if (i == (int)res2.size() - 1) break;
    cout << res2[i].first << ' ' << res2[i + 1].first << endl
         << res2[i].second << ' ' << res2[i + 1].second << endl;
  }
  return 0;
}
