Re: [Tutor] First Try 1.2

2006-02-23 Thread Alan Gauld
Hi John, Its developing nicely so I'll add some more style issue comments :-) > import random > > # store the /home/mutt/lotto.txt in f > f = file('/home/mutt/lotto.txt','w') > # create or replace lotto.txt in my home directory > f.write('Here are your numbers:\n\n') I'd move the middle comment

Re: [Tutor] First Try 1.2

2006-02-22 Thread John Connors
G'day Kent, Thanks for the input. >The comments don't really add anything to the program. Comments that >restate exactly what the code is doing are not that helpful. The code >should be clear by itself. As a beginner they may seem like a helpful >crutch but you will get better at reading the cod

Re: [Tutor] First Try 1.2

2006-02-22 Thread Kent Johnson
John Connors wrote: > import random > > # store the /home/mutt/lotto.txt in f > f = file('/home/mutt/lotto.txt','w') > # create or replace lotto.txt in my home directory > f.write('Here are your numbers:\n\n') > The comments don't really add anything to the program. Comments that restate exactl

Re: [Tutor] First Try 1.2

2006-02-22 Thread John Connors
G'day, Added a power ball option to the lotto program today. The program does way more then I ever intended when I started it so I'll try a new project. Maybe I'll come back to it when I try out Tkinter and try to give it a GUI. Anywayhere's my latest effort. import random # store the /h

[Tutor] First Try 1.2

2006-02-21 Thread John Connors
G'day :) I've added a little more to the program. It now sorts the game numbers from lowest to highest which makes filling out the tickets a lot easier, I've been putting off doing this because I wasn't sure how to go about it but once I started looking I found python does it all for me with .s