int yellow = 9;
int red = 5;
void setup() {
pinMode(yellow, OUTPUT); // sets the digital pin 10 (yellow pin) as output
pinMode(red, OUTPUT); // sets the digital pin 11 (red pin) as output
}
void loop() {
digitalWrite(yellow, HIGH);
// waits 1.5 seconds
delay(1500);
// sets the yellow pin off
digitalWrite(yellow, LOW);
// sets the red pin on
digitalWrite(red, HIGH);
// wait for 3 seconds
delay(3000);
// sets the red pin off
digitalWrite(red, LOW);