The odds are stacked mightily against you as far as winning the lottery. But just how bad are those odds? Use our simple online calculator to find out. We based our calculations on the numbers used in the state lottery in the US, but you can experiment with other states’ lotteries too. (Just make sure that the data set you’re using is as large as possible to get a more accurate picture.)

The calculator is based on mathematics and probabilities theories applied to lottery drawings. It adopts a coloured template that determines all the combinations of numbers with highest probability to win, as established by Pascal’s rule.

It can also be used to identify the most likely number combinations in a given lottery draw. For example, in a six-out-of-49 lottery game, the chance that two numbers drawn in the same game will match is one in 13,983,816. This is because, for any given six-number combination, there are a total of 10 ways to obtain the same result in two drawsâ€”four more than the amount needed for a winning ticket.

The NYC Department of Education uses a lottery system to assign students to schools, but the DOE has been reluctant to provide much information about how lottery numbers are determined or on the odds of being assigned to various schools. This has puzzled and infuriated parents, who believe that their children are unfairly penalized if they draw a poor lottery number. But we found that comparing the first eight characters of lottery numbers gives more than 4 billion possibilitiesâ€”and there is only a 50% chance that two students’ lottery numbers will be identical within a year.