Tuples part 2

bearophileHUGS at lycos.com bearophileHUGS at lycos.com
Thu Jun 5 01:37:08 CEST 2008


victor.hera... at gmail.com:

Do you mean something like this? (notice the many formatting
differences, use a formatting similar to this one in your code)

coords = []

for i in xrange(1, 5):
    for j in xrange(1, 5):
        for k in xrange(1, 2):
            coords.append( (i, j, k) )

coords *= 10
print coords

Bye,
bearophile



More information about the Python-list mailing list