Re: an adventure: a Lisp-style linked list

[email protected] (Pierre Asselin) Thu, 4 Sep 2025 18:41:27 -0000 (UTC)
Newsgroups comp.lang.python
Organization PANIX Public Access Internet and UNIX, NYC
Message-ID <[email protected]>
Ethan Carter <[email protected]> wrote:

>   def __init__(self, d, ls):
>     self.head = d
>     self.tail = ls

Why not
    def __init__(self, d, ls=None):

and avoid the need for a List.Empty ?

-- 
pa at panix dot com