Expected Initializer? I keep getting the error "Expected initializer" at different points in my code whenever I try to verify it. Currently, the error exists before "void setup." How can I fix this error and not allow it to happen in the future?

int ledPins[] = {9, 8, 7, 6};
int index;
int currentLED


void setup();
  {
  pinMode(Led1Pin, OUTPUT);
  pinMode(Led2Pin, OUTPUT);
  pinMode(Led3Pin, OUTPUT);
  pinMode(Led4Pin, OUTPUT);
  pinMode(Led5Pin, OUTPUT);
  pinMode(ButtonPin, INPUT);

  Serial.begin(9600);

  //Start a new game.




 for(index = 0; index &lt;= 4; index++)
  {
    pinMode(ledPins[index],OUTPUT);
    // ledPins[index] is replaced by the value in the array.
    // For example, ledPins[0] is 2
  }
}



void loop()
{

  oneAfterAnotherNoLoop();  // Light up all the LEDs in turn


}

void oneAfterAnotherNoLoop()
{
  int delayTime = 200; // time (milliseconds) to pause between LEDs
                   // make this smaller for faster switching
  // turn all the LEDs on:
  int Index;

for (Index = 0; Index &lt;=3; Index++) {
  digitalWrite(ledPins[Index], HIGH);
  delay(delayTime);
  digitalWrite(ledPins[Index], LOW);
}
for (Index = 3; Index &gt;= 0; Index--) {
    digitalWrite(ledPins[Index], HIGH);
  delay(delayTime);
  digitalWrite(ledPins[Index], LOW);
}
}

void loop();
{
    // Check if the button is pressed at the right moment

   if (digitalRead(10) == 0) 
   {
    if (currentLED == 8)
    {
      // Blink the orrect (green) LED
      digitalWrite(8, HIGH);
      delay(200);
      digitalWrite(14, LOW);
      delay(200);
      digitalWrite(8, HIGH);
      delay(200);
      digitalWrite(14, LOW);
    }
    }
  }
int currentLED


You are missing a semicolon there.



void setup();


There should not be a semicolon here.



Do some tutorials on the C or C++ language. They will help you.