Summary:
When a unit engages in melee combat with a city, the city may take damage to its hit points, and the melee unit may suffer damage as well. No matter how few hit points the city has remaining, it always defends itself at its full combat strength.