Smile and be nice. If you've had a bad day, leave it at home and be polite while on shift, even to the meanest of customers. You don't need to be a pushover, but you're more likely to leave your customer happy and satisfied if you're slower but in a great mood than if you're the fastest cashier ever but snappy and rude. If you can't sincerely be cheerful, at least try and fake it.