x = input()
y = input()
if x == y and (x == 'синий' or x == 'желтый' or x == 'красный') and (y == 'красный' or y == 'синий' or y == 'желтый'):
print(x)
elif (x == 'красный' or y == 'красный') and (x == 'синий' or y == 'синий'):
print('фиолетовый')
elif (x == 'красный' or y == 'красный') and (x == 'желтый' or y == 'желтый'):
print('оранжевый')
elif (x == 'синий' or y == 'синий') and (x == 'желтый' or y == 'желтый'):
print('зеленый')
elif x != 'синий' and x != 'желтый' and x != 'красный' or y != 'красный' and y != 'синий' and y != 'желтый':
print('ошибка цвета')
я это уже решал на stepik
uses crt;
const g=9.8;
var i:integer;
t:real;
begin
writeln('h g');
for i:=1 to 20 do
begin
t:=sqrt(2*i/g);
writeln(i,' ',t:0:3);
end;
end.