I can tell you that cashiers, like any other people, can sometimes make rude or inappropriate comments unintentionally or due to various reasons. It's essential to remember that everyone has their own struggles and bad days, which may lead to less than ideal interactions.
If you encounter a rude comment from a cashier or anyone else, it's best to remain calm and composed. You can address the situation politely or choose to ignore the comment and move on. Reacting with rudeness in return usually doesn't lead to a positive outcome. If you feel the comment was inappropriate or offensive, you could speak to the store manager or customer service representative to express your concerns.
Remember that everyone deserves to be treated with respect and kindness, even in challenging situations.