int timer =100;
void setup() {
for (int pin = 2; pin < 8; pin++){
pinMode(pin, OUTPUT);
}
}
void loop() {
for(int pin =2; pin<8; pin++){
digitalWrite(pin, HIGH);
delay(timer);
digitalWrite(pin, LOW);
}
for(int pin=7; pin >=2; pin --){
digitalWrite(pin,HIGH);
delay(timer);
digitalWrite(pin,LOW);
}
}