Hi,i got it from whizlab practice exam 4.
output:4
I am not getting how the split() works here?
If i change the above code as
String str="aa";
String[] s=str.split("a{3}");
gives output as 1.
I am really confused ,because it should be three occurences of "a" but here only "aa" are in the string str.
please expalin me..
Thanks
Preetha
( Jesper Young: Added code tags )
[ December 15, 2008: Message edited by: Jesper Young ]