import machine
from machine import Pin
#ENTRADA
A_in = Pin(19, Pin.IN, Pin.PULL_UP)
B_in = Pin(15, Pin.IN, Pin.PULL_UP)
#SALIDA
led_suma = Pin(13, Pin.OUT)
led_carry = Pin(14, Pin.OUT)
while True:
A = A_in.value()
B = B_in.value()
And = (A and B)
Xor = (not A and B) or (A and not B)
led_suma.value(Xor)
led_carry.value(And)