Pl's give me an example. I want split my data using regExp. ex ;"simon josap josap simaon 233467". like that data set i want split using regExp. pl's give a sampal code.
private static String TestOne() {
String regex = " \\n"; String input = "Full Name First Name Last Name Phone Number"; Pattern p = Pattern.compile(regex); Matcher m = p.matcher(input); String[]items = p.split(regex); return items[0];
Look at the documentation for String. String.split() takes a regex.
Jeremy Kraybill
Austin, TX
hi,
Thanks. I serch that one. But I havent Idea.
Pl's give me an example. I want split my data using regExp. ex ;"simon josap josap simaon 233467". like that data set i want split using regExp. pl's give a sampal code.
private static String TestOne() {
String regex = " \\n";
String input = "Full Name First Name Last Name Phone Number";
Pattern p = Pattern.compile(regex);
Matcher m = p.matcher(input);
String[]items = p.split(regex);
return items[0];
}
This code is not working. Help me.