Код: Выделить всё
class NoEvent:
``` a bare class flag signifying process returned nothing (NOT None) ```
pass
def event_gen():
``` can sometimes output a value (of any type) or be silent ```
if (random < 0.2):
return None
if (0.2
Подробнее здесь: [url]https://stackoverflow.com/questions/79835345/implement-a-sentinel-flag-without-an-arbitrary-value[/url]
Мобильная версия