#include <bits/stdc++.h>
int main() {
  long long t;
  std::cin >> t;
  while (t--) {
    std::string A;
    std::cin >> A;
    bool flag1 = false;
    bool flag2 = false;
    long long sum = 0;
    long long chet = 0;
    for (auto i = 0; i < A.length(); ++i)
      if ((A[i] - '0') % 2 == 0) {
        flag1 = true;
        ++chet;
      }
    long long zeroSum = 0;
    for (auto i = 0; i < A.length(); ++i)
      if (A[i] == '0') flag2 = true;
    for (long long i = 0; i < A.length(); ++i) {
      sum += A[i] - '0';
      if (A[i] == '0') ++zeroSum;
    }
    if ((flag2 && flag1 && (sum % 3 == 0) && chet > 1) || zeroSum == A.length())
      std::cout << "red\n";
    else
      std::cout << "cyan\n";
  }
}
