Hay people, i need some help here, my task doesn't pass the last condition...
package com.codegym.task.task08.task0818;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
/*
Only for the rich
*/
public class Solution {
public static HashMap<String, Integer> createMap() {
//write your code here
HashMap<String, Integer> map = new HashMap<>();
map.put("Jankovic", 2500);
map.put("Umicevic", 450);
map.put("Vrucinic", 700);
map.put("Radisic", 490);
map.put("Pejasinovic", 420);
map.put("Njenjic", 700);
map.put("Licina", 2000);
map.put("Babic", 2120);
map.put("Popovic", 3300);
map.put("Zupic", 2200);
return map;
}
public static void removeItemFromMap(HashMap<String, Integer> map) {
//write your code here
HashMap<String, Integer> copy = new HashMap<>(map);
HashSet<Integer> copyInteger = new HashSet<Integer>(copy.values());
for (Integer st : copyInteger) {
if (st < 500) {
map.remove(st);
}
}
}
public static void main(String[] args) {
}
}