#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  ;
  int n;
  cin >> n;
  vector<string> v(n);
  for (int i = 0; i < n; i++) {
    cin >> v[i];
  }
  for (int i = 0; i < n; i++) {
    long long sum = 0;
    int ten = 0;
    bool even = false;
    string s = v[i];
    for (int j = 0; j < s.size(); j++) {
      if ((s[j] == '0') && (ten == 0)) {
        ten = 1;
        continue;
      }
      if ((s[j] - '0') % 2 == 0) {
        even = true;
      }
      sum += (s[j] - '0');
    }
    if (sum == 0)
      cout << "red"
           << "\n";
    else if ((even) && (sum % 3 == 0) && (ten))
      cout << "red"
           << "\n";
    else
      cout << "cyan"
           << "\n";
  }
  return 0;
}
