const int buttonOn = 2;
const int buttonOff = 3;
const int PinLed = 9;
int botonOn = 0;
int botonOff = 0;
void setup() {
pinMode(buttonOn, INPUT);
pinMode(buttonOff, INPUT);
pinMode(PinLed, OUTPUT);
digitalWrite(PinLed, LOW);
}
void loop() {
botonOn = digitalRead(buttonOn);
botonOff = digitalRead(buttonOff);
if (botonOn == HIGH) {
digitalWrite(PinLed, HIGH);
}
if (botonOff == HIGH) {
digitalWrite(PinLed, LOW);
}
delay(50);
}