I have to split a given string (eg: "The dog plays in the rain"
) to create an array of string ({"The","Dog","plays", "in", "the","raine}
). I cannot use split or any other predefined method. I tried to go through the array with a loop and to make it create a new substring made of the previous word every time it hit a space but without success...
Thanks in advance :)
Aucun commentaire:
Enregistrer un commentaire