Why does this (not) work?

Skip Montanaro skip at pobox.com
Tue Aug 19 17:45:09 EDT 2003


    Skip> To force the * operation to be evaluated first you need to add some parens:

    Skip>     ("%s - %s - %s" % (("test",))*3)

Ack!  Should have been what I entered at the >>> prompt:

    "%s - %s - %s" % (("test",)*3)

(Stupid copy-n-paste!)

Skip





More information about the Python-list mailing list