This is a little simulation to show how likely it is that you will win a prize on the UK national lottery assuming you buy 1 ticket for each draw.
randomize timer()
six = rnd(13983815) +1
fiveb = rnd(2330635)+1
five = rnd(55491)+1
four = rnd(1032)+1
three = rnd(56)+1
do
won=0
draws = draws +1
dsix = rnd(13983815) +1
dfiveb = rnd(2330635)+1
dfive = rnd(55491)+1
dfour = rnd(1032)+1
dthree = rnd(56)+1
if dthree = three then print "Draw#", draws, "- 3 Numbers (press a key)" :won=1: wait key
if dfour = four then print "Draw# ", draws, "- 4 numbers (press a key)" :won=1:wait key
if dfive = five then print "Draw# ", draws, "- 5 numbers (press a key)" :won=1:wait key
if dfiveb = fiveb then print "Draw# ", draws,"- 5 numbers + bonus (press a key)" :won=1:wait key
if dsix = six then print "Draw# ", draws,"- 6 numbers (press a key)" :won=1:wait key
if won=0 then print "Draw# ", draws,"- No win"
loop
and this simulation simulates your chance of winning the big prize
randomize timer()
six = rnd(13983815) +1
fiveb = rnd(2330635)+1
five = rnd(55491)+1
four = rnd(1032)+1
three = rnd(56)+1
do
won=0
draws = draws +1
dsix = rnd(13983815) +1
`dfiveb = rnd(2330635)+1
`dfive = rnd(55491)+1
`dfour = rnd(1032)+1
`dthree = rnd(56)+1
`if dthree = three then print "Draw#", draws, "- 3 Numbers (press a key)" :won=1: wait key
`if dfour = four then print "Draw# ", draws, "- 4 numbers (press a key)" :won=1:wait key
`if dfive = five then print "Draw# ", draws, "- 5 numbers (press a key)" :won=1:wait key
`if dfiveb = fiveb then print "Draw# ", draws,"- 5 numbers + bonus (press a key)" :won=1:wait key
if dsix = six then print "Draw# ", draws,"- 6 numbers (press a key)" :won=1:wait key
`if won=0 then print "Draw# ", draws,"- No win"
loop
Yes, Im very bored..! Odds taken from the uk lotto web site.
Week number 18338455
6 numbers for santa yay! Ok so this may not be the most interesting submision but the geek in me found it interesting. It kinda makes me wander why i buy tickets on a weekly basis.