Do you really mean that with 30 days in stead of 1 day, you have 29% more chance? Or is it 30 times as much, which is 2900% more chance? In that case I wouldn't write the program yourself.

The best program to use depends on where the needed data - about visitors and (number of) visits - is stored. But if it's accessible in Excel, a lottery program is easy to write in a macro using the RAND or RANDBETWEEN function.