#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  string s;
  int f, g, h, len, sum;
  long long int t;
  cin >> t;
  while (t--) {
    cin >> s;
    f = 0, g = 0, sum = 0;
    len = s.length();
    for (long long int i = 0; i < len; i++) {
      if (s[i] == '0' && g == 0)
        g = 1;
      else if (((int)s[i] - 48) % 2 == 0 && f == 0)
        f = 1;
      sum += (int)s[i] - 48;
    }
    if (f && g && sum % 3 == 0)
      cout << "red\n";
    else
      cout << "cyan\n";
  }
}
