Problem with nested for loops and servos

Very hard to read your code... see note from @groundFungus

And as per the note from @Paul_KD7HB Serial.println() is very useful for debugging.

Your loops should be structured like this...

  
while (true)
{
  Serial.println ("Start");
  
  for (int x = 0; x < 4; x++)
  {

    for (int y = 0; y < 3; y++)
    {
      Serial.println("Servo S2");
      delay(500);
    }

    Serial.println("Servo S7");
    delay(500);
  }

  Serial.println("Servo S5");
  delay(500);
  
}

Output

Start
Servo S2
Servo S2
Servo S2
Servo S7
Servo S2
Servo S2
Servo S2
Servo S7
Servo S2
Servo S2
Servo S2
Servo S7
Servo S2
Servo S2
Servo S2
Servo S7
Servo S5
Start