void setup() {
pinMode(0, OUTPUT);
pinMode(11, INPUT);
}
void loop() {
if (digitalRead(11) == LOW) {
digitalWrite(0, LOW);
delay(100);
digitalWrite(0, HIGH);
delay(100);
} else {
digitalWrite(0, LOW);
}
}
void setup() {
pinMode(0, OUTPUT);
pinMode(11, INPUT);
}
void loop() {
if (digitalRead(11) == LOW) {
digitalWrite(0, LOW);
delay(100);
digitalWrite(0, HIGH);
delay(100);
} else {
digitalWrite(0, LOW);
}
}