В ide все работает
package com.javarush.task.task04.task0416;
/*
Переходим дорогу вслепую
*/
import java.io.*;
public class Solution {
public static void main(String args[]) throws IOException {
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
String s = reader.readLine();
int a = Integer.parseInt(s);
if (a <= 3 && a >= 1) {
System.out.println("зеленый");
} else if (a <= 4 && a >= 3) {
System.out.println("красный");
} else if (a <= 5 && a >= 4) {
System.out.println("желтый");
} else if (a <= 8 && a >= 5) {
System.out.println("зеленый");
}
}
}