I think the idea here is that babies (and likely women) aren't part of Hamas so there is 0 justification for killing them. Of course innocent men shouldn't be killed, either, but they could claim they are Hamas militants whereas babies can't be soldiers