Type mismatchings and the rank newbie

John Brawley jgbrawley at earthlink.net
Fri Mar 16 23:21:18 CET 2001


Rank newbie here, trying to do something specific.
I need to use a set of numbers (say, 1 to 25), and create 25 lists from the
numbers (1 thru 25), which lists have a character "P" and a number (one of
the 25).

The lists I want look like :
P1=[x, y, z]
P2=[x, y, z]
P3=[x, y, z]
(etcetera down to P25)

The user inputs the number that creates the lists, so I can't just write 25
lists (the number could be anywhere from 13 to 500 or more).

I need to write a loop that takes each number in sequence and sticks it next
to the ascii "P" so that when the loop is finished, I end up with a set of
lists each of whose names is different by one number.

The loop is not a problem; I just can't figure how to stick a different
number form the user input total, into the second place of the list name
(  Pn=[x, y, z] where 'n' is the number stuck in there by the loop) with
every iteration of the loop.

The docs are confusing to me (I'm not a programmer and don't want to be, but
there is no other way for me to do what I need to to see what this program
will display for me).

Can anyone suggest a way out of this hole?

Thanks!

--
JB
jgbrawley at earthlink.net
Web: http://www.jcn1.com/jbrawley
          http://home.earthlink.net/~jgbrawley





More information about the Python-list mailing list