I went to Las Vegas for a conference recently, and I came out ahead. I didn’t do this at the blackjack table or the roulette wheel, though. I did it at Starbucks. Specifically, I earned 97 cents in pure profit on April 2 through “Starbucks arbitrage” at Harrah’s Casino.

Here’s what happened. I was at the 2012 Association of Private Enterprise Education meeting at Harrah’s Casino in Las Vegas. There’s a Starbucks in the lobby at Harrah’s, but if you go right around the corner and up an escalator, there’s another Starbucks. I noticed that the upstairs Starbucks normally had a much shorter line.

On Tuesday morning, I had a bit of time and decided to do an experiment. I mentioned to people in the long line at the downstairs Starbucks that there’s another Starbucks a few short steps away with what’s probably a much shorter line. I don’t know that more than one or two people noticed. I then went upstairs, bought two Grande Dark Roast coffees for $7.03 and brought them downstairs. I announced to the people standing in line that I had bought them upstairs, and I ended up selling them (quickly) to a gentleman in the downstairs line for $8.

What I earned was a pure profit. According to the economist Israel Kirzner, profit emerges when alert entrepreneurs notice that the structure of production is out of whack in some way. In this case, I noticed that there might be a difference in the price I would have to pay for a cup of Starbucks coffee in one market (upstairs) and the price I could get for it in another (downstairs).

Activity like this is the source of an entrepreneur’s profit. Some successful entrepreneurs come up with better and cheaper ways of doing things. The people at Apple, for example, thought (correctly) that people would be willing to pay for a device that puts the world’s information in the palms of their hands or that would allow them to do things like write articles about entrepreneurship with their thumbs while lying on their living room couches (like I did with the first draft of this article, for example).

Other successful entrepreneurs earn profits by noticing opportunities that others have overlooked. Arbitrage is one such opportunity—buying a good in one market and then selling it for a higher price in another. The profit I earned buying coffee upstairs and selling it downstairs was a profit of this kind. I bought low, at a price the upstairs Starbucks was willing to accept. We were both better off. I sold high, at a price someone standing in line at the downstairs Starbucks was willing to accept. Again, we were both better off. Was anyone exploited or defrauded? No. Trade created wealth, even though the act of trading itself did not produce any additional coffee.

Contrary to popular belief, entrepreneurs’ profits in free markets are not ripped from the hides of the workers. Profit is a reward for taking a risk and choosing wisely. I didn’t know for certain that someone would be willing to pay more than $7.03 for my two cups of coffee. The 97 cents I earned was my reward for taking a risk on my hunch that two cups of coffee would be more valuable downstairs than upstairs. I was right, and I used part of the proceeds from my sale to pay for postage so I could send postcards to my kids.

According to Deirdre McCloskey, this is the key to the wealth of the modern world. That we live in a world in which buying low and selling high is at least tolerated encourages economic growth. The great irony of this is that merchants tend to be scorned or otherwise not trusted. But who is the real public servant: the politician deciding he will take more of your money by force so that he can accomplish his goals, or the merchant who decides he wants more of your money and offers you a hot cup of tasty coffee in return?

So here’s part of the lesson: Support your local merchant, and begrudge him not his profits. He earned them by risking his livelihood and his well-being on his expectation about how much you wanted that cup of coffee (or whatever it was). Without his intervention, getting that coffee would have been harder. If anyone is a real public servant, it isn’t a politician. It’s your local merchant.