file handling issues

leo.carnovale at gmail.com leo.carnovale at gmail.com
Fri Sep 6 06:20:02 EDT 2013


I am making this little game and I am trying to make some sort of script that does the following:
>Checks to see if a file exists
 >If it does, check the numbers in it
 >If it doesn't, make one and fill it with some numbers
>Sorts out if the numbers in the file are in the right format
 >If they are, then store them
 >If not, remake it again
>THEN, check if there is a pass.
 >If there is, check if it fits the key and go on if so
 >If not, ask for a new one, check it, go on if its correct.

Every time I run it, it says the key is 0!?
I can not for the life of me figure out what it is doing.

The code:
<https://docs.google.com/document/d/1_Qo4bgmNhRer3fAt3EAtPNSei4N2q58f_q4_9r6OHbw/edit?usp=sharing>

Thanks

Leo



More information about the Python-list mailing list