The New York Police Department doesn't have a face. if you ATTEMPTED to punch an officer in the face, the LEAST that would happen is being arrested for assaulting an officer. You would be LUCKY if that was the worst injury you sustained.
Consequences comes as obvious fine & jail time, considered under "assaulting a law enforcement officer", but sometimes this is also considered as an aggravated assault and result in a felony. Look at it this way, the officer has done nothing to you, yet you consider to punch him. Followed by that you either get taken down by the cop himself coz these cops are no joke, they get serious training and they're good at this. If somehow you manage to escape the crime scene, the cops hunt you down, and adhere an additional charge of escaping crime scene, avoiding arrest that definitely is going to make you end up in a jail, followed by a series of investigation and court time
參考: Say thankyou instead. Cops are doing a great job for country, being selfless.