что не так?
public class Solution {
public static void main(String[] args) throws IOException {
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
ArrayList<String> months = new ArrayList<String>(Arrays.asList("January", "February", "March", "April",
"May", "June", "July", "August", "September", "October", "November", "December"));
String s = reader.readLine();
for(String d : months) {
if(s.equals(d)) {
System.out.println(s+ " is the "+(months.indexOf(d)+1)+" month.");
break;
} } } }