from machine import Pin
from time import sleep
button = Pin(16,Pin.IN,Pin.PULL_DOWN)
led = Pin(15,Pin.OUT)
while True:
if button.value() == 1:
led.value(1)
print("button with light")
else:
led.value(0)
print("button without light")