#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1000005;
string s[MAXN];
map<int, vector<pair<string, int>>> v[26];
vector<string> v2[MAXN];
vector<pair<string, string>> res;
int num[MAXN], vis[MAXN], sum = 0, sum_res = 0;
int cnt[MAXN];
int n;
int p = 1, q = 0;
pair<string, string> get() {
  while (q + 1 >= num[p]) ++p, q = 0;
  pair<string, string> ret = {v2[p][q], v2[p][q + 1]};
  q += 2;
  return ret;
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> s[i];
    int x = 0;
    for (auto c : s[i])
      if (((c) == 'a' || (c) == 'e' || (c) == 'i' || (c) == 'o' || (c) == 'u'))
        ++cnt[i], x = c - 'a';
    v[x][cnt[i]].push_back({s[i], i});
    num[cnt[i]]++;
  }
  for (int i = 1; i <= 1000000; i++) sum += num[i] / 2;
  for (int i = 0; i < 26; i++) {
    for (auto y : v[i]) {
      int j = y.first;
      vector<pair<string, int>> &g = y.second;
      int sz = g.size();
      for (int k = 0; k + 1 < sz; k += 2) {
        if (sum_res + 1 <= sum - 1) {
          res.push_back({g[k].first, g[k + 1].first});
          vis[g[k].second] = 1;
          vis[g[k + 1].second] = 1;
          sum_res++;
          sum--;
          num[j] -= 2;
        }
      }
    }
  }
  for (int i = 1; i <= n; i++) {
    if (vis[i]) continue;
    v2[cnt[i]].push_back(s[i]);
  }
  cout << res.size() << endl;
  for (auto &w : res) {
    pair<string, string> cur = get();
    cout << cur.first << " " << w.first << endl;
    cout << cur.second << " " << w.second << endl;
  }
  return 0;
}
