#include <iostream>
#include <cstdio>
#include <algorithm>
#include <map>
#include <vector>

using namespace std;

string s[8] = {"black", "blue", "lime", "aqua", "red", "fuchsia", "yellow", "white"};

int main(){
	
	string str;
	
	while(true){
		cin >> str;
		if(str[0] == '0'){
			break;
		}
		int ans = 0;
		if(str[1] < '0' || str[1] > '7'){
			ans += 4;
		}
		if(str[3] < '0' || str[3] > '7'){
			ans += 2;
		}
		if(str[5] < '0' || str[5] > '7'){
			ans += 1;
		}
		cout << s[ans] << endl;
	}
	
	return 0;
}