I am writing a basic command line application in an online and very limited environment. How would I make a for loop that: defines a new object then runs a method from that object?

I already have this yet the method part returns a error. As stated earlier i'm using a very limited environment and it did not given any info on the error.

for z in range(5):
    for zz in range(7):
        globals()['variable{}{}'.format(z,zz)] = an_object.thing("parm", 2, False)

0 Answers