In article <[email protected]>, Chris Angelico <[email protected]> wrote:
> You can't store a list in memory; what you store is a set of bits > which represent some metadata and a bunch of pointers. Well, technically, what you store is something which has the right behavior. If I wrote: my_huffman_coded_list = [0] * 1000000 I don't know of anything which requires Python to actually generate a million 0's and store them somewhere (even ignoring interning of integers). As long as it generated an object (perhaps a subclass of list) which responded to all of list's methods the same way a real list would, it could certainly build a more compact representation. -- https://mail.python.org/mailman/listinfo/python-list
