On Fri, Nov 21, 2014 at 4:54 PM, Gill Shen <gillar...@gmail.com> wrote:
> How is this behavior implemented under the hood? And why is this allowed at 
> all? Is it just a curiosity or can you do something useful with it?

Simple: The list contains itself. When you dereference the list, you
get back the original list. It does have value; you just have to be
careful of any recursive operation like printing it out - the repr()
for a list carefully checks for this.

ChrisA
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to