int led=2;
int button=3;
int statusbutton=0;
void setup() {
pinMode(led, OUTPUT);// put your setup code here, to run once:
pinMode(button, INPUT);
}
void loop() {
statusbutton=digitalRead(button);
if (statusbutton==1){
count++;
delay(300);
}
if(count==1) {
digitalWrite(led, HIGH);
}
if(count==2){
digitalWrite(led, LOW);
count=0;
}