#include <bits/stdc++.h>
using namespace std;
long long oo = (long long)1e9;
template <typename T>
using V = vector<T>;
inline void fastInOut() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
}
inline bool taxi(string &s) {
  return ((s[0] == s[1] && s[1] == s[3] && s[3] == s[4] && s[4] == s[6] &&
           s[6] == s[7])
              ? 1
              : 0);
}
inline bool pizza(string &s) {
  if (s[0] > s[1] && s[1] > s[3] && s[3] > s[4] && s[4] > s[6] && s[6] > s[7])
    return 1;
  return 0;
}
unordered_map<string, long long> taxii, pizzaa, cafe;
int main() {
  fastInOut();
  long long n, x, ind = 0;
  cin >> n;
  string s, str;
  V<string> arr(n);
  while (n--) {
    cin >> x >> s;
    for (long long i = 0; i < x; i++) {
      cin >> str;
      if (pizza(str))
        pizzaa[s]++;
      else if (taxi(str))
        taxii[s]++;
      else
        cafe[s]++;
    }
    arr[ind++] = s;
  }
  long long mxt = 0, mxp = 0, mxc = 0;
  string anst, ansp, ansc;
  for (auto i : taxii) {
    if (i.second > mxt) mxt = i.second;
  }
  for (auto i : pizzaa) {
    if (i.second > mxp) mxp = i.second;
  }
  for (auto i : cafe) {
    if (i.second > mxc) mxc = i.second;
  }
  bool engzt = 0, engzp = 0, engzc = 0;
  for (auto i : arr) {
    if (!engzt && taxii[i] == mxt) {
      anst += i;
      engzt = 1;
    } else if (engzt && taxii[i] == mxt)
      anst += ", " + i;
    if (!engzp && pizzaa[i] == mxp) {
      ansp += i;
      engzp = 1;
    } else if (engzp && pizzaa[i] == mxp)
      ansp += ", " + i;
    if (!engzc && cafe[i] == mxc) {
      ansc += i;
      engzc = 1;
    } else if (engzc && cafe[i] == mxc)
      ansc += ", " + i;
  }
  cout << "If you want to call a taxi, you should call: " << anst << ".\n";
  cout << "If you want to order a pizza, you should call: " << ansp << ".\n";
  cout << "If you want to go to a cafe with a wonderful girl, you should call: "
       << ansc << ".\n";
  return 0;
}
