print("this program is to make:\n")
print("\t a red LED turn ON for the wrong guessing\n")
print("\t a blue LED turn ON for the correct guessing\n")
print("Remarks: No limit on guessing trials\n\n")

from machine import Pin
from utime import sleep 

led_red = Pin(14, Pin.OUT)   
led_blue = Pin(12, Pin.OUT)

target = 33

while True:

    value = int(input("Enter an integer between 1 and 100:" ))

    if value > target:
     print("WRONG!", value, " is high/ too high")
     for i in range(3):
        led_red.on()
        sleep(1)
        led_red.off()
        sleep(1)
        led_blue.off()
        sleep(1)
    

    elif int(value) < target:
     print("WRONG!", value, " is low/ too low")
     for i in range(3):
        led_red.on()
        sleep(1)
        led_red.off()
        sleep(1)
        led_blue.off()
        sleep(1)
      

    else:
     print("Perfect Kudos!")
     for i in range(3):
        led_blue.on()
        sleep(1)
        led_blue.off()
        sleep(1)
        led_red.off()
        sleep(1)
        break