Java brise la corde en mots
String s = "I want to walk my dog";
String[] arr = s.split(" ");
for ( String ss : arr) {
System.out.println(ss);
}
Karamolegkos
String s = "I want to walk my dog";
String[] arr = s.split(" ");
for ( String ss : arr) {
System.out.println(ss);
}
{
public static void main(String args[])
{
String str = "Hey this is Ram";
String [] words = str. split(" ", 3);
for (String word : words)
System. out. println(word);