Hasn’t csuebele already recommended to do stuff like this with Arrays?
You could first create an Array of names and then use that in the for-clause.
Edot: Or, if no specific names are necessary, simply use the variable of the for-clause as a String.