Hi Ethan,
> When using the class in practice, I've found it natural to
> create instances of Foo so that the instance itself is called
> name. Thus, I find myself doing things like:
>
a=Foo('a')
b=Foo('b')
>
This is very common at the interactive prompt.
However its nearly always the w
Ethan Ligon wrote:
> I've devised a simple class; one of the class attributes is an identifier.
>
> Thus,
>
> class Foo:
> def __init__(self,name):
> self.name=name
>
> When using the class in practice, I've found it natural to
> create instances of Foo so that the instance itself is calle
I've devised a simple class; one of the class attributes is an identifier.
Thus,
class Foo:
def __init__(self,name):
self.name=name
When using the class in practice, I've found it natural to
create instances of Foo so that the instance itself is called
name. Thus, I find myself doing thi