'''
Problem statement 6
LED control using switch (with external resistor for switch)
'''
from machine import Pin as pin
from time import sleep
led=pin(4,pin.OUT)
switch=pin(14,pin.IN)
while True:
value=switch.value()
if value==1:
led.on()
else:
led.off()