+ 1
Split java negative arg
Why put a negative number arg to string split method in java? The result is the same without second arg... https://code.sololearn.com/cCOLoI2AGTjs/?ref=app
1 Antwort
+ 3
A positive number n means : maximum number of splits need is n. No beyond it.
A negative number n means : split as many as possible.
A number 0 means : split as many as possible but ignore or discard trailing empty strings.
hope it helps..