The moral of this story is that the markets are inefficient, and the whole religion we've built around the theory of efficient markets is a false one.
If you can't (or won't) make accurate value judgements on products, you'll lose every time. The house has the advantage, as it were.
Why does the customer visit the restaurant in the first place? To maximize efficiency? And this irrational act of a dessert makes it inefficient?
People value things in different ways, it's really a complex equation and you are over simplifying it. Maybe the experience of getting a free dessert is more valuable than saving the cash. It is a service business after all.
Free markets aren't always easy to understand, but they always give people more of what they want in aggregate than any mechanism of force.
I'm not the one oversimplifying it.