I have a string say 123dance456
which I need to split into two strings containing the first sub-string before the sub-string dance
(i.e. 123
) and after the sub-string dance
(i.e. 456
). I need to find them and hold them in separate string variables, say String firstSubString = 123;
and String secondSubString = 456;
.
Is there any given String method that does just that?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…