In the case of sloppy writing, the letter will be ejected from the sorting machine and reviewed by a human (same process as for illegible addresses).
If a human cannot find a match then the sender will receive a request to pay for the missing postage (presuming the code is invalid). If the sender is unknown the recipient will receive a payment request (which can be appealed).
Speaking from experience you would normally want the letter to arrive at its destination so I take care to write the code very clearly. I imagine this is true for most people.
You massively underestimate the care or thought some Americans give to anything including legibly writing an address; very cool look into how USPS handles that situation (link free to read without subscription)
If a human cannot find a match then the sender will receive a request to pay for the missing postage (presuming the code is invalid). If the sender is unknown the recipient will receive a payment request (which can be appealed).
Speaking from experience you would normally want the letter to arrive at its destination so I take care to write the code very clearly. I imagine this is true for most people.