#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<pair<int, string> > taxi;
  vector<pair<int, string> > pizza;
  vector<pair<int, string> > girl;
  vector<string> vs;
  int mta = 0, mpz = 0, mgl = 0;
  for (int i = 0; i < n; i++) {
    int m;
    cin >> m;
    string s;
    cin >> s;
    vs.push_back(s);
    int ta = 0, pz = 0, gl = 0;
    for (int j = 0; j < m; j++) {
      string t;
      cin >> t;
      vector<int> v;
      v.push_back(t[0] - '0');
      v.push_back(t[1] - '0');
      v.push_back(t[3] - '0');
      v.push_back(t[4] - '0');
      v.push_back(t[6] - '0');
      v.push_back(t[7] - '0');
      bool ck = true;
      int p = v.size();
      for (int k = 0; k < p - 1; k++) {
        if (v[k] <= v[k + 1]) {
          ck = false;
          break;
        }
      }
      if (ck)
        pz++;
      else {
        ck = true;
        for (int k = 0; k < p - 1; k++) {
          if (v[k] != v[k + 1]) {
            ck = false;
            break;
          }
        }
        if (ck)
          ta++;
        else
          gl++;
      }
    }
    if (ta > 0) {
      taxi.push_back(make_pair(ta, s));
      mta = max(mta, ta);
    }
    if (pz > 0) {
      pizza.push_back(make_pair(pz, s));
      mpz = max(mpz, pz);
    }
    if (gl > 0) {
      girl.push_back(make_pair(gl, s));
      mgl = max(gl, mgl);
    }
  }
  int q = taxi.size();
  vector<string> vt;
  for (int j = q - 1; j >= 0; j--) {
    if (taxi[j].first == mta) vt.push_back(taxi[j].second);
  }
  reverse(vt.begin(), vt.end());
  cout << "If you want to call a taxi, you should call: ";
  int x = vt.size();
  if (x == 0) {
    for (int j = 0; j < n; j++) {
      cout << vs[j];
      if (j != (n - 1)) {
        cout << ", ";
      }
    }
    cout << "." << endl;
  } else {
    for (int j = 0; j < x; j++) {
      cout << vt[j];
      if (j != (x - 1)) {
        cout << ", ";
      }
    }
    cout << "." << endl;
  }
  q = pizza.size();
  vector<string> vp;
  for (int j = q - 1; j >= 0; j--) {
    if (pizza[j].first == mpz) vp.push_back(pizza[j].second);
  }
  reverse(vp.begin(), vp.end());
  cout << "If you want to order a pizza, you should call: ";
  x = vp.size();
  if (x == 0) {
    for (int j = 0; j < n; j++) {
      cout << vs[j];
      if (j != (n - 1)) {
        cout << ", ";
      }
    }
    cout << "." << endl;
  } else {
    for (int j = 0; j < x; j++) {
      cout << vp[j];
      if (j != (x - 1)) {
        cout << ", ";
      }
    }
    cout << "." << endl;
  }
  q = girl.size();
  vector<string> vg;
  for (int j = q - 1; j >= 0; j--) {
    if (girl[j].first == mgl) vg.push_back(girl[j].second);
  }
  reverse(vg.begin(), vg.end());
  cout
      << "If you want to go to a cafe with a wonderful girl, you should call: ";
  x = vg.size();
  if (x == 0) {
    for (int j = 0; j < n; j++) {
      cout << vs[j];
      if (j != (n - 1)) {
        cout << ", ";
      }
    }
    cout << "." << endl;
  } else {
    for (int j = 0; j < x; j++) {
      cout << vg[j];
      if (j != (x - 1)) {
        cout << ", ";
      }
    }
    cout << "." << endl;
  }
  return 0;
}
