So typical, real classic....."the maria is not working." I play along [providing, of course, he is headed in the right direction]; when we get to the destination, I first exit the cab, then give him what I think the proper fare should be. If he doesn't accept it, I drop it in his lap or the passenger seat and walk away. This same thing has happened to me several times, usually with the driver saying something to me like "muy malo."

It's always a good idea to have small colone bills and coins with you to give the driver the right amount so he does not need to give you change.
