Re: How to print random strings

2005-11-03 Thread nak
[EMAIL PROTECTED] wrote: > Im at the end of chapter 3 of "Python Programming For The Absolute > Beginner, Michael Dawson " and he asks to make a fortune program that > displays a fortune each time its ran, and to have 5 unique fortunes. > > Whats confusing is that, he never discussed how to do this

Re: How to print random strings

2005-11-03 Thread Magnus Lycka
[EMAIL PROTECTED] wrote: > So how would I go about have 5 strings, and running a program that will > randomly pick one of those to print? >>> import random >>> text = "Perhaps reading the manual is a good idea?".split() >>> random.choice(text) 'is' >>> random.choice(text) 'reading' >>> random

Re: How to print random strings

2005-11-02 Thread Mike Meyer
[EMAIL PROTECTED] writes: > Im at the end of chapter 3 of "Python Programming For The Absolute > Beginner, Michael Dawson " and he asks to make a fortune program that > displays a fortune each time its ran, and to have 5 unique fortunes. > > Whats confusing is that, he never discussed how to do th

Re: How to print random strings

2005-11-02 Thread Jorge Godoy
[EMAIL PROTECTED] writes: > Im at the end of chapter 3 of "Python Programming For The Absolute > Beginner, Michael Dawson " and he asks to make a fortune program that > displays a fortune each time its ran, and to have 5 unique fortunes. > > Whats confusing is that, he never discussed how to do t

How to print random strings

2005-11-02 Thread theboringdays
Im at the end of chapter 3 of "Python Programming For The Absolute Beginner, Michael Dawson " and he asks to make a fortune program that displays a fortune each time its ran, and to have 5 unique fortunes. Whats confusing is that, he never discussed how to do this. The only thing he talked about w