from machine import Pin
led_red = Pin(1, Pin.OUT)
led_orange = Pin(5, Pin.OUT)
led_blue = Pin(9, Pin.OUT)
led_yellow = Pin(13, Pin.OUT)
while 1:
color = input('input color ')
if color == 'red':
led_red.on()
led_orange.off()
led_blue.off()
led_yellow.off()
print('RED is ON')
if color == 'orange':
led_orange.on()
led_red.off()
led_blue.off()
led_yellow.off()
print('ORANGE is ON')
if color == 'blue':
led_blue.on()
led_orange.off()
led_red.off()
led_yellow.off()
print('BLUE is ON')
if color == 'yellow':
led_yellow.on()
led_orange.off()
led_red.off()
led_blue.off()
print('YELLOW is ON')