I tried to explain your problem in post #6. Did you have any questions about what I said there.
Did you try the code I posted?
Type: Posts; User: Norm
I tried to explain your problem in post #6. Did you have any questions about what I said there.
Did you try the code I posted?
The doc doesn't quite tell how to code it
String [] text = {"late" ,"train", "is", "again", "the"};
text.split(",");
The problem with your code is that text is not a String.
Its an array of...
Read the API doc for the split() method. What does it take for an argument?
What argument did you give it in the code you posted?
[Ljava.lang.String
That is how the compiler refers to a String...
Look at the String class's split method. It will help you extract the words from the string.