14 May String split(String regex, int limit) method in Java
The split(String regex, int limit) method in Java splits this string around matches of the given regular expression.
Syntax
Let us see the syntax,
Parameters
Let us see the parameters,
- regex − delimiting regular expression
- limit − the result threshold, the limit of the strings to be returned
Example
The following is an example of String[] split(String regex, int limit),
Output
The following is the output,
No Comments