I tried your suggestion in post 4, but apparently I typed it in a bit wrong.
Tried it again and it works. Thanks!
Type: Posts; User: Gugubo
I tried your suggestion in post 4, but apparently I typed it in a bit wrong.
Tried it again and it works. Thanks!
Maybe I'll rephrase.
So this is my code:
String[] stringArray = {"hello","world","test","whatever"};
System.out.println("stringArray: "+ java.util.Arrays.toString(stringArray));...
Eclipse gives an error: "Array constants can only be used in initializers." in this line:
stringArray = {"banana","fish","tree","apple"};
How can I change a complete array when it's already initialized?
Can I change this array:
String[] stringArray = {"hello","world","test","whatever"};
to this:
...