#include <bits/stdc++.h>
using namespace std;
template <class S, class T>
pair<S, T> operator+(const pair<S, T> &s, const pair<S, T> &t) {
  return pair<S, T>(s.first + t.first, s.second + t.second);
}
template <class S, class T>
pair<S, T> operator-(const pair<S, T> &s, const pair<S, T> &t) {
  return pair<S, T>(s.first - t.first, s.second - t.second);
}
template <class S, class T>
ostream &operator<<(ostream &os, pair<S, T> p) {
  os << "(" << p.first << ", " << p.second << ")";
  return os;
}
template <class T>
bool chmax(T &a, const T &b) {
  if (a < b) {
    a = b;
    return 1;
  }
  return 0;
}
template <class T>
bool chmin(T &a, const T &b) {
  if (a > b) {
    a = b;
    return 1;
  }
  return 0;
}
const long long inf = 1000000001;
const long long INF = (long long)1e18 + 1;
const double pi = 3.14159265358979323846;
long long dx_ori[4] = {-1, 0, 1, 0}, dy_ori[4] = {0, 1, 0, -1};
long long dx[4] = {0, 0, 0, 0}, dy[4] = {0, 0, 0, 0};
long long dx2[8] = {1, 1, 0, -1, -1, -1, 0, 1},
          dy2[8] = {0, 1, 1, 1, 0, -1, -1, -1};
const long long MOD = 1000000007;
signed main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  ;
  long long n;
  cin >> n;
  for (long long i = 0; i < (n); i++) {
    string s;
    cin >> s;
    bool zero = false, two = false;
    long long add = 0;
    for (long long i = 0; i < (s.size()); i++) {
      if (s[i] == '0') {
        if (not zero)
          zero = true;
        else
          two = true;
      } else if ((long long)(s[i] - '0') % 2 == 0)
        two = true;
      add += (long long)(s[i] - '0');
    }
    if (add % 3 == 0 and zero and two) {
      cout << "red" << endl;
    } else {
      cout << "cyan" << endl;
    }
  }
}
