Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Multicolored Lamp by DaI17
class Lamp:
lamp_color = ("Green", "Red", "Blue", "Yellow")
def __init__(self):
self.count = 0
def light(self):
self.count += 1
return Lamp.lamp_color[(self.count-1) % 4]
Feb. 17, 2020
Comments: