You need to use the actual iterator and its remove method if you want to modify the collection while looping over it. There isn't really any way to do it with the foreach construct.
If you're trying to remove multiple entries in one iteration, you'll need to loop over something that's not backed by the map.
Set keys = new HashSet(group0.keySet());
for (String key : keys) {
if (group0.containsKey(key)) {
Integer value = group0.get(key);
//your stuff
}
}