#include <bits/stdc++.h>
using namespace std;
const double PI = acos(-1.0);
int toInt(string s) {
  int r = 0;
  istringstream sin(s);
  sin >> r;
  return r;
}
long long toInt64(string s) {
  long long r = 0;
  istringstream sin(s);
  sin >> r;
  return r;
}
double toDouble(string s) {
  double r = 0;
  istringstream sin(s);
  sin >> r;
  return r;
}
double dist(double x1, double y1, double x2, double y2) {
  return sqrt(((x1 - x2) * (x1 - x2)) + ((y1 - y2) * (y1 - y2)));
}
bool isUpperCase(char c) { return c >= 'A' && c <= 'Z'; }
bool isLowerCase(char c) { return c >= 'a' && c <= 'z'; }
bool isLetter(char c) { return c >= 'A' && c <= 'Z' || c >= 'a' && c <= 'z'; }
bool isDigit(char c) { return c >= '0' && c <= '9'; }
char toLowerCase(char c) { return (isUpperCase(c)) ? (c + 32) : c; }
char toUpperCase(char c) { return (isLowerCase(c)) ? (c - 32) : c; }
template <class T>
inline T strTo(string s) {
  istringstream is(s);
  T v;
  is >> v;
  return v;
}
template <class T>
inline string toStr(const T& v) {
  ostringstream os;
  os << v;
  return os.str();
}
template <class T>
inline int cMin(T& a, const T& b) {
  return b < a ? a = b, 1 : 0;
}
template <class T>
inline int cMax(T& a, const T& b) {
  return a < b ? a = b, 1 : 0;
}
template <class T>
inline int cBit(T n) {
  return n ? cBit(n & (n - 1)) + 1 : 0;
}
template <class T>
inline T lowbit(T n) {
  return (n ^ (n - 1)) & n;
}
template <class T>
inline T GCD(T a, T b) {
  if (a < 0) return GCD(-a, b);
  if (b < 0) return GCD(a, -b);
  return (b == 0) ? a : GCD(b, a % b);
}
template <class T>
inline T LCM(T a, T b) {
  if (a < 0) return LCM(-a, b);
  if (b < 0) return LCM(a, -b);
  return a * (b / gcd(a, b));
}
struct node {
  int x, y, z;
  string name;
} d[1000];
int main() {
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    int si;
    cin >> si >> d[i].name;
    d[i].x = d[i].y = d[i].z = 0;
    for (int j = 0; j < si; j++) {
      string str;
      cin >> str;
      if (str[0] == str[1] && str[0] == str[3] && str[0] == str[4] &&
          str[0] == str[6] && str[0] == str[7])
        d[i].x++;
      else if (str[0] > str[1] && str[1] > str[3] && str[3] > str[4] &&
               str[4] > str[6] && str[6] > str[7])
        d[i].y++;
      else
        d[i].z++;
    }
  }
  int maxx = 0, maxy = 0, maxz = 0;
  for (int i = 0; i < n; i++) {
    maxx = max(maxx, d[i].x);
    maxy = max(maxy, d[i].y);
    maxz = max(maxz, d[i].z);
  }
  cout << "If you want to call a taxi, you should call: ";
  bool flag = false;
  for (int j = 0; j < n; j++)
    if (maxx == d[j].x) {
      if (flag)
        cout << ", ";
      else
        flag = true;
      cout << d[j].name;
    }
  cout << "." << endl;
  cout << "If you want to order a pizza, you should call: ";
  flag = false;
  for (int j = 0; j < n; j++)
    if (maxy == d[j].y) {
      if (flag)
        cout << ", ";
      else
        flag = true;
      cout << d[j].name;
    }
  cout << "." << endl;
  cout
      << "If you want to go to a cafe with a wonderful girl, you should call: ";
  flag = false;
  for (int j = 0; j < n; j++)
    if (maxz == d[j].z) {
      if (flag)
        cout << ", ";
      else
        flag = true;
      cout << d[j].name;
    }
  cout << "." << endl;
  return 0;
}
