On 2016-04-11 10:45, Ben Finney wrote: > Also, there is another obvious way to create an empty tuple: call > the ‘tuple’ type directly: > > >>> foo = tuple() > >>> print(type(foo), len(foo)) > <class 'tuple'> 0
But here the parens make the tuple too: >>> foo = tuple >>> print(type(foo)) <class 'type'> >>> len(foo) Traceback (most recent call last): File "<stdin>", line 1, in <module> TypeError: object of type 'type' has no len() (totally just yanking chains, throwing pebbles in the pond to watch the ripples, and otherwise sewing confusion ;-) -tkc -- https://mail.python.org/mailman/listinfo/python-list