#include <bits/stdc++.h>
using namespace std;
struct custom_hash {
  static uint64_t splitmix64(uint64_t x) {
    x += 0x9e3779b97f4a7c15;
    x = (x ^ (x >> 30)) * 0xbf58476d1ce4e5b9;
    x = (x ^ (x >> 27)) * 0x94d049bb133111eb;
    return x ^ (x >> 31);
  }
  size_t operator()(uint64_t x) const {
    static const uint64_t FIXED_RANDOM =
        chrono::steady_clock::now().time_since_epoch().count();
    return splitmix64(x + FIXED_RANDOM);
  }
};
unsigned long long bpow(unsigned long long a, long long n, long long mod) {
  return n ? n & 1 ? (bpow(a, n - 1, mod) * a) % mod
                   : (bpow((a * a) % mod, n >> 1ll, mod)) % mod
           : 1ll;
}
int get_digit(long long num, int len, int index) {
  return num / bpow(10, len - index - 1, 1) % 10;
}
long long digit_sum(long long num) {
  long long dig_sum = 0;
  while (num > 0) {
    dig_sum += num % 10;
    num /= 10;
  }
  return dig_sum;
}
const long double EPS = 0.000001;
const long long MOD = 1000000007;
const long long INF = 1e18;
const double pi = 2 * acos(0.0);
long long n, m, k, p, q, t, sum = 0, cnt = 0;
long long mx = INT64_MIN;
long long mn = INT64_MAX;
bool flag = 0;
vector<long long> v;
string s = "", s1, s2;
void bad_solve() {}
char b = 'B', w = 'W';
long long bb = 0, ww = 0;
void flip(long long idx) {
  if (s[idx] == b) {
    --bb;
    ++ww;
    s[idx] = w;
  } else {
    ++bb;
    --ww;
    s[idx] = b;
  }
}
void solve() {
  cin >> t;
  while (t--) {
    cin >> s;
    n = s.size();
    bool ok1 = 0, ok2 = 0;
    sum = 0;
    long long idx;
    for (long long i = 0; i < n; ++i) {
      if (s[i] == '0') {
        idx = i;
        ok1 = 1;
      }
      sum += s[i] - '0';
    }
    for (long long(i) = 0; (i) < (n); ++(i)) {
      if (((s[i] - '0') * 10) % 4 == 0 && i != idx) {
        ok2 = 1;
        break;
      }
    }
    if (sum % 3 == 0 && ok1 && ok2)
      cout << "red" << endl;
    else
      cout << "cyan" << endl;
  }
}
int main() {
  cout.precision(20);
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  solve();
  return 0;
}
