« first day (1963 days earlier)      last day (1378 days later) » 

dMd
4:32 PM
please help me look at this code stackoverflow.com/questions/62727943/…
 
1 message moved from Python
 
 
6 hours later…
10:36 PM
>>> def generate():
...     class SketchyBool:
...         counter = 0
...         def __init__(self):
...             self.boolcounts = []
...         def __bool__(self):
...             self.boolcounts.append(SketchyBool.counter)
...             SketchyBool.counter += 1
...             return False
...         def __str__(self):
...             return str(self.boolcounts)
...
...     return SketchyBool(), SketchyBool()
...
... x,y = generate()
... z = x or y
... print(x, y)
...
... x,y = generate()
1 message moved from Python
 

« first day (1963 days earlier)      last day (1378 days later) »