Thats cause "names" is an Array of String objects and not a String itself.
If you need to display the contents of "names" use a loop like:-
for(int i=0;i<names.length;i++) {
System.out.println(names[i]);
}
BTW you seriously need to learn how to indent your code, this should help you get started.