Kay Schluehr <[EMAIL PROTECTED]> wrote: ... > > >> range(3)**2 > > [(0,0), (0,1), (0,2), (1,0), (1,1), (1,2), (2,0), (2,1), (2,2)] ... > But why isn't this interpreted as [0, 1, 4] like it is in Mathematica?
Since range(3)*2 is [0, 1, 2, 0, 1, 2], it would be horribly, painfully inconsistent if **2 was interpreted as "square each item". Alex -- http://mail.python.org/mailman/listinfo/python-list