#include <bits/stdc++.h>
using namespace std;
int n;
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0);
  cin >> n;
  for (int i = 1; i <= n; i++) {
    string y;
    int s, even;
    bool zero;
    cin >> y;
    s = 0;
    even = 0;
    zero = 0;
    for (auto it : y) {
      int yi;
      yi = it - '0';
      s += yi;
      if (yi == 0) zero = 1;
      if (yi % 2 == 0) even++;
    }
    if (s % 3 == 0 && zero && even >= 2) {
      cout << "red\n";
    } else {
      cout << "cyan\n";
    }
  }
  return 0;
}
