Cracking the Scratch Lottery Code
- By Jonah Lehrer
- January 31, 2011 |
- 12:00 pm |
- Wired February 2011
Mohan Srivastava, a geological statistician living in Toronto, was working in his office in June 2003, waiting for some files to download onto his computer, when he discovered a couple of old lottery tickets buried under some paper on his desk. The tickets were cheap scratchers—a gag gift from his squash partner—and Srivastava found himself wondering if any of them were winners. He fished a coin out of a drawer and began scratching off the latex coating. “The first was a loser, and I felt pretty smug,” Srivastava says. “I thought, ‘This is exactly why I never play these dumb games.’”
The second ticket was a tic-tac-toe game. Its design was straightforward: On the right were eight tic-tac-toe boards, dense with different numbers. On the left was a box headlined “Your Numbers,” covered with a scratchable latex coating. The goal was to scrape off the latex and compare the numbers under it to the digits on the boards. If three of “Your Numbers” appeared on a board in a straight line, you’d won. Srivastava matched up each of his numbers with the digits on the boards, and much to his surprise, the ticket had a tic-tac-toe. Srivastava had won $3. “This is the smallest amount you can win, but I can’t tell you how excited it made me,” he says. “I felt like the king of the world.”
Delighted, he decided to take a lunchtime walk to the gas station to cash in his ticket. “On my way, I start looking at the tic-tac-toe game, and I begin to wonder how they make these things,” Srivastava says. “The tickets are clearly mass-produced, which means there must be some computer program that lays down the numbers. Of course, it would be really nice if the computer could just spit out random digits. But that’s not possible, since the lottery corporation needs to control the number of winning tickets. The game can’t be truly random. Instead, it has to generate the illusion of randomness while actually being carefully determined.”
Srivastava speaks quietly, with a slight stammer. He has a neatly trimmed beard and a messy office. When he talks about a subject he’s interested in—and he’s interested in many things, from military encryption to freshwater fossils—his words start to run into each other.
As a trained statistician with degrees from MIT and Stanford University, Srivastava was intrigued by the technical problem posed by the lottery ticket. In fact, it reminded him a lot of his day job, which involves consulting for mining and oil companies. A typical assignment for Srivastava goes like this: A mining company has multiple samples from a potential gold mine. Each sample gives a different estimate of the amount of mineral underground. “My job is to make sense of those results,” he says. “The numbers might seem random, as if the gold has just been scattered, but they’re actually not random at all. There are fundamental geologic forces that created those numbers. If I know the forces, I can decipher the samples. I can figure out how much gold is underground.”
Srivastava realized that the same logic could be applied to the lottery. The apparent randomness of the scratch ticket was just a facade, a mathematical lie. And this meant that the lottery system might actually be solvable, just like those mining samples. “At the time, I had no intention of cracking the tickets,” he says. He was just curious about the algorithm that produced the numbers. Walking back from the gas station with the chips and coffee he’d bought with his winnings, he turned the problem over in his mind. By the time he reached the office, he was confident that he knew how the software might work, how it could precisely control the number of winners while still appearing random. “It wasn’t that hard,” Srivastava says. “I do the same kind of math all day long.”
That afternoon, he went back to work. The thrill of winning had worn off; he forgot about his lunchtime adventure. But then, as he walked by the gas station later that evening, something strange happened. “I swear I’m not the kind of guy who hears voices,” Srivastava says. “But that night, as I passed the station, I heard a little voice coming from the back of my head. I’ll never forget what it said: ‘If you do it that way, if you use that algorithm, there will be a flaw. The game will be flawed. You will be able to crack the ticket. You will be able to plunder the lottery.’”
The North American lottery system is a $70 billion-a-year business, an industry bigger than movie tickets, music, and porn combined. These tickets have a grand history: Lotteries were used to fund the American colonies and helped bankroll the young nation. In the 18th and 19th centuries, lotteries funded the expansion of Harvard and Yale and allowed the construction of railroads across the continent. Since 1964, when New Hampshire introduced the first modern state lottery, governments have come to rely on gaming revenue. (Forty-three states and every Canadian province currently run lotteries.) In some states, the lottery accounts for more than 5 percent of education funding.
While approximately half of Americans buy at least one lottery ticket at some point, the vast majority of tickets are purchased by about 20 percent of the population. These high-frequency players tend to be poor and uneducated, which is why critics refer to lotteries as a regressive tax. (In a 2006 survey, 30 percent of people without a high school degree said that playing the lottery was a wealth-building strategy.) On average, households that make less than $12,400 a year spend 5 percent of their income on lotteries—a source of hope for just a few bucks a throw.
Pages: Previous 1 2 3 4 | Full Page | Next
Frank Norris’s McTeague contains a classic lottery story. McTeague’s girl, Trina, a perfect match to your socio-economic demographic for ticket buyers, wins a lottery (at play for Norris was Naturalism’s chance – no gaming going on), ends up cashing it in for coins, ends up sleeping on the coins, much to McTeague’s dismay. What happens to lottery winners might be the focus of your next post on the subject. Do they get “re-wired”?
Great article.
It is funny to think that we just assume that because the government and large amounts of cash are involved that these scratcher games are perfectly designed! Great article and it has refreshed my gambling addiction! When an article strikes a chord like that it was written well.
Great article, very well written, educational and interesting. But I must say the photograph/portrait does not match the caliber of the article. Hire out that photo assignment?
When she won again in July, 2010, it was reported that Joan Ginther, (the lady who has won the TX scratch off lotteries multiple times) was a retired college level math professor with a doctorate in math from Stanford.
Please do not delete this post as it does not link or mention other publications. Thank you.
Very interesting read. Thank you.
@techydude: is this your way to diss an award winning photographer?
Very nice job. This could be the seeds of a full-blown book.
Wouldn’t the easiest solution be to just cover all the numbers with latex so that none would be visible? It might cost fractionally more to produce the tickets, but surely the measure would pay for itself.
Srivastava didn’t want to spend his days scratching cards, but considered consulting for the boards… Hmmm could also be paid for consulting for those who want to win, either for the cash or for the laundering. Kind of like the hacker who breaks a program ends up with a good job working for MicroSoft.
OK … Here’s the deal … If you find a flaw in a lottery … DON’T TELL THE LOTTERY! … Tell you family … Tell your friends … But DON’T TELL THE LOTTERY!
A partial reason why break even tickets are underreported is that the stores selling them will just turn over new tickets to the winners without cashing them out.
Strange, the simple solution would be to put latex on the visible digits as well. ASFAIK that’s exactly what the state lottery in Sweden does with these kinds of tickets.
Linatur and Amag, they can’t latex over the visible number because the player needs to see them to ‘play the game’. You scratch off the hidden numbers and match them in the game area.
What could be done is to either wrap the game in a sealed opaque plastic envelope or print the game card with a fold out flap to cover the game area. The lotteries don’t want to do this because it makes it more expensive to print.
Great article, Jonah!
At university, a few decades ago (also in Canada) I cracked a similar “bingo lottery” with just one winner by the SUN newspaper tabloid, one ticket per newspaper. You could tell nearly all the non-winners, in a similar way. So I went to their rival, with the story, back then, but they wouldn’t publish it – honor amongst thieves, or they thought they might want to do the same thing later, I suppose. Not sure whether that was Calgary or Edmonton.
And later there was another skewed Provincial Alberta ticket lottery that (at first) didn’t use up the last series before the draw, so those were way more likely to win per ticket, ’cause they KEPT the series number and would just redraw for the rest, as I remember. Don’t know if that was ever discovered or published either.
Yes, they need the numbers. And they’ll find them by scratching the second field. Just as they’d do by removing your opaque envelope (why not make it out of latex instead of plastic?).
Interesting story!
Now how about examining the lotto type games?
I was talking with someone from the California lottery where I found out that they don’t use the balls anymore (and haven’t for years) for drawing the winning numbers. All the numbers are random generated from a computer program down in Texas by (I think) G-Tech (the vendor).
Personally, I think they have a poorly designed random number program or are using some common seed because too often, the generated numbers you get when you purchase tickets seem to be stuck or repeat. I’ve seen a lot of strange sequences over the years!
But not being a math guy, I wouldn’t know how to prove anything on my own.
very interesting article. what pisses me off is that if a private citizen ran a “lottery game” as fixed as the government’s, they’d be thrown in jail. The government is a mafia just like organized crime.
I understand the concern of lottery officials about the possibility of lottery codes being cracked. But except for gangsters using lottery wins to launder money, I can’t gin up much outrage of my own. If large sums of money are being paid out, I’d prefer they go to people bright enough to break difficult algorithms rather than to pathetic souls dumb to spend 5% of an already inadequate income gambling. Surely a “retired college level math professor with a doctorate in math from Stanford” is going to make more productive use of her millions.
Think about the legal implications of the last sentence of this article. It is possible that the TX lottery officials know that Joan Ginther cracked the game. If they acknowledge it publicly, they could pave the way for a class-action lawsuit by the millions of people who played with no chance of winning because negligent game design allowed it to be cracked.
First Auto-Tune and now they’re reverse engineering the Lottery… won’t these geological analysts ever stop their mischief-making?
Big props to Mr Srivastava. Now.. back to work finding those gold mines, you!
OMG, it’s a real Laslo Hollyfeld! http://www.google.com/imgres?imgurl=http://manwithpez.com/wp-content/uploads/2010/06/lazlo.jpg&imgrefurl=http://manwithpez.com/tag/lazlo-hollyfeld/&usg=__UHpGZMXxlgLkwDgNgpkv2zvZhVE=&h=381&w=700&sz=166&hl=en&start=0&zoom=1&tbnid=0T0C5GTp2JBuoM:&tbnh=124&tbnw=159&ei=uu9RTbqzH8qr8Ab8vPTfCA&prev=/images%3Fq%3Dlazlo%2Bhollyfeld%26hl%3Den%26client%3Dfirefox-a%26hs%3D88e%26sa%3DX%26rls%3Dorg.mozilla:en-US:official%26biw%3D1485%26bih%3D561%26tbs%3Disch:1%26prmd%3Divnso&itbs=1&iact=rc&dur=413&oei=uu9RTbqzH8qr8Ab8vPTfCA&esq=1&page=1&ndsp=27&ved=1t:429,r:0,s:0&tx=75&ty=86
yea, theres an app (Android) for that.
Why does every assume organized crime would not take a loss to clean their earnings? 53 cents clean is a lot better than $1 dirty.
“It’s a constant race to stay ahead of the bad guys.”
Wow, you keep uneducated people in a cycle of false hope, despair and poverty, yet you call someone who figures out a way to beat your scam as a bad guys. These guys’ moral compassed is truly effed up.
Some of the payout ratios could be explained quite easily. I bought a ticket for $2, and it won $20. I kept $10, and bought 5 more tickets with the other half of the winnings. I won $20 off those tickets too, so I did the same thing, keep half, but more with the other half of the winnings. The winning streak stayed alive for 14 rounds of this style, some times I won a lot more, some times less. I still pocketed over $250 when all was said and done, from my original $2 investment.
If someone used the same strategy and had a decent payout, say $100 on the first ticket, they could do really well. Each strip of tickets that they sell (they come attached in strips of 50 to 100 tickets) has a certain amount of winners, with some decent sized ones thrown in from time to time. So if the free money was used to buy whole strips at a time, there will be a whole bunch of free tickets, and winners to keep going until some larger ones hit.
When I was a teenager I worked part-time in a convenience store, and got to see the frequency of payouts, and how many times I won (I’d get bored and play if it was slow). I won $250 three times, $150 five times, and I don’t remember how many times I won $25 and $50, plus all the little $5 or free tickets in a two year period. Then again, I have always been lucky with those kinds of things, but still it’s not like I played every day, or even every shift.
Another fantastic example of Wired journalism. Great job. Very interesting.