int i=0;
int j=0;
void setup() {
// put your setup code here, to run once:
pinMode(2, INPUT_PULLUP); pinMode(1, OUTPUT);
pinMode(10, INPUT_PULLUP); pinMode(13, OUTPUT);
}
void loop() {
// put your main code here, to run repeatedly:
if( digitalRead(2)==0)
{
while(digitalRead(2)==0)
{delay(500);}
i++;
}
if(i%2==0)
{
digitalWrite(1,1);
}
else
{
digitalWrite(1,0);
}
if( digitalRead(10)==0)
{
while(digitalRead(10)==0)
{delay(500);}
j++;
}
if(j%2==0)
{
digitalWrite(13,1);
}
else
{
digitalWrite(13,0);
}
}