последний пункт не проходит на компе как не менял и что не менял все работает а тут не пойму
package com.javarush.task.task08.task0816;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.*;
/*
Добрая Зинаида и летние каникулы
*/
public class Solution {
public static Map<String, Date> createMap() throws ParseException {
DateFormat dateFormat = new SimpleDateFormat("MMMMM d yyyy", Locale.ENGLISH);
Map<String, Date> map = new HashMap<>();
map.put("Сталлоне", dateFormat.parse("MAY 1 2012"));
map.put("Сталоне", dateFormat.parse("MAY 1 2013"));
map.put("Сталлое", dateFormat.parse("MAY 1 2016"));
map.put("Сталлон", dateFormat.parse("MAY 1 2014"));
map.put("Сталне", dateFormat.parse("MAY 1 2002"));
map.put("Стаионе", dateFormat.parse("JUNE 1 2012"));
map.put("Стне", dateFormat.parse("MAY 1 2017"));
map.put("Сталло", dateFormat.parse("MAY 1 2008"));
map.put("Сталлпроне", dateFormat.parse("MAY 1 2006"));
map.put("Сталаве", dateFormat.parse("MAY 1 2004"));
//напишите тут ваш код
return map;
}
public static void removeAllSummerPeople(Map<String, Date> map) {
//напишите тут ваш код
Iterator<Map.Entry<String, Date>>it = map.entrySet().iterator();
Map.Entry<String,Date> pair=it.next();
if(pair.getValue().getMonth()==5 || pair.getValue().getMonth()==6|| pair.getValue().getMonth()==7) {
it.remove();
}
}
public static void main(String[] args) {
}
}