Split ("\\ s");
// Split a string with a regex for whitespace
String[] resultRegex = inputStr.split("\\s");
Doochi
// Split a string with a regex for whitespace
String[] resultRegex = inputStr.split("\\s");
public class MyClass {
public static void main(String args[]) {
String data = "1,2,3,,5,6,,";
String[] split = data.split(",", -1);
for (int i=0; i<split.length; i++)
System.out.println(split[i]);
System.out.println("Done");
}
}