This website requires Javascript to function properly.


Gaming the System: How to Win the Lottery with Math

Learn about permutations and how they can be used!


A guy once won the lottery because he figured out all the possible number combinations and bought every possible combination. He figured out that the amount he’d spend on tickets was less than the prize. And when you have every possible ticket, you’re guaranteed to win.


The guy is Stefan Mandel, and he won the lottery 14 times. He would get people to invest (put in) enough money to buy all the combinations of numbers. Then they would wait until the jackpot was high enough for everyone to make some money. Buy every possible combination. Profit.


This sort of scheme is against the rules now for almost every lottery, so don’t ask your parents to help you out. Also, the big lotteries have made it so there are so many possible combinations of numbers that you could never buy enough tickets to make a profit. Sorry.kid with money


The math behind Mandel’s lottery scheme is the study of permutations and combinations. So what’s a permutation? What’s a combination? What’s the difference between the two?


Let’s start with combinations. Simply put, it is a group. Mary, Bob, and Tina is a combination of three friends. Tina, Mary and Bob are the same combination. Or 0123 is the same combination as 3201.


A permutation is a specific group within a combination. Mary, Bob and Tina is a different permutation than Tina, Mary, and Bob. See?


Think about it like your locker at school. The dial probably goes from 0 to 30. If the code to unlock your locker is 15-7-28, you have to use that permutation to open it. Not just any combination of 7, 15, and 28 will open the locker.


So what if you wanted to sneak into your friend’s locker? How many possible codes could there be? With a typical school lock, it would be 27,000 possible codes!


How do we get that number? By calculating 30³, that is 30 to the third power, or 30 x 30 x 30!


Mandel did this and found the lottery had about five million possible numbers. So if each ticket was a dollar and the jackpot was ten million, he’d double the money! Next, he went about writing a computer program to print off every possible permutation.


Mandel had a team of people going around all over buying ten thousand tickets at a time. And it worked! Mandel’s idea won! The only problem was the state didn’t like it. It took four years for lawyers to argue that they did technically win fair and square. No rule had been made about buying all the numbers.


So it turns out that math can be enriching. Get it? Enriching, because you can win the lottery and get rich. Bad jokes aside, understanding how math works outside of normal everyday addition, subtraction, multiplication, and division can be very useful. From opening your locker after winter break, to computer security, building databases, and hacking the lottery, understanding permutations and finding all of them is important.


What is your favorite food to cook over the grill in summer?

shadow graphic