Programmer looking for a Programmer for 1 job
-
Required Knowledge
PHP, HTML
-
Additional Info
I need a lottery checker for the Power Ball. There's 9 ways to win as described here: http://powerball.com/powerball/pb_prizes.asp
First download this file: http://powerball.com/powerball/winnums-text.txt
Now create an HTML form. In this form, the person enters their winning numbers. I'm thinking of letting them enter 5 plays at once, like a real lottery ticket. I think it'd be better to leave the date off the form and search the whole list, then display any "hits" for all dates. It's kinda fun that way to see if your numbers have ever hit, not just for that day's lottery.
So I'm guessing you'll create a loop with sub loops to check for all possible winning combinations. Not really sure. I'm thinking you'd check the powerball number first as that's a guaranteed win of "something". From there check to see how many regular numbers match by calling another function or something. You can win "something" without the powerball if you have at least 3 regular numbers. The "9 ways to win" kinda complicates things, and it's beyond my inadequate mind.
This is a pretty good example of what I want: http://www.molottery.com/inputPBTickets.do
If the person doesn't click for "check back to 1997", then check back for 1 year (104 most recent drawings), and automagically convert "1" to "01" so the user doesn't have to worry about it when entering their numbers in the form.
Tags
php
-
Comments
You need to be logged in to make a comment. Make an Offer
You need to be logged in to make an offer.-