On 11/14/2020 4:09 AM, Manfred Lotz wrote:
On 11 Nov 2020 19:21:57 GMT
r...@zedat.fu-berlin.de (Stefan Ram) wrote:
In my Python course I gave the assignment to define a
counter class "Main" so that
counter0 = Main()
counter1 = Main()
counter1.count(); counter1.count(); counter1.count()
c
On Sat, 14 Nov 2020 05:08:07 -0600
2qdxy4rzwzuui...@potatochowder.com wrote:
> On 2020-11-14 at 10:09:32 +0100,
> Manfred Lotz wrote:
>
> > On 11 Nov 2020 19:21:57 GMT
> > r...@zedat.fu-berlin.de (Stefan Ram) wrote:
> >
> > > In my Python course I gave the assignment to define a
> > > cou
On 2020-11-14 at 10:09:32 +0100,
Manfred Lotz wrote:
> On 11 Nov 2020 19:21:57 GMT
> r...@zedat.fu-berlin.de (Stefan Ram) wrote:
>
> > In my Python course I gave the assignment to define a
> > counter class "Main" so that
> >
> > counter0 = Main()
> > counter1 = Main()
> > counter1.count();
On 11 Nov 2020 19:21:57 GMT
r...@zedat.fu-berlin.de (Stefan Ram) wrote:
> In my Python course I gave the assignment to define a
> counter class "Main" so that
>
> counter0 = Main()
> counter1 = Main()
> counter1.count(); counter1.count(); counter1.count()
> counter1.count(); counter1.count()
On 13/11/2020 08:47, Alan Bawden wrote:
r...@zedat.fu-berlin.de (Stefan Ram) writes:
I expected this solution:
class Main:
def __init__( self ):
self.value = 0
def count( self ):
self.value += 1
but a student turned in the following so
r...@zedat.fu-berlin.de (Stefan Ram) writes:
I expected this solution:
class Main:
def __init__( self ):
self.value = 0
def count( self ):
self.value += 1
but a student turned in the following solution:
class Main:
value = 0
def