for any loop, you do not need to put in any semicolon at it's end. Like here you did,
for(int counter = 0; counter < arraytest.length; counter++); // This semicolon doesn't live here{
System.out.println(arraytest[counter]);
}
it'd be better if you make this to:
for(int counter = 0; counter < arraytest.length; counter++) {
System.out.println(arraytest[counter]);
And if you really want the counter to be incremented by 1, then why put the counter++ twice? That doesn't make it an efficient program and moreover it may result in a possible bugged output, because it gets incremented by 2 everytime the loop runs, once while entering and while taking the exit because of the duplicate counter++. Suggest you to remove it unless you require, else if you really require, then instead of placing two counter++ you may put this:
for(int counter = 0; counter < arraytest.length; counter = counter + 2) {
System.out.println(arraytest[counter]);
}
I hope I may have helped you. Thanks!