0
About separate a string
a little question.. if there is a string which like S65S7352S7357S636S5262S5 is it possible to separate all the item to S65 S7352 S7357 S636 S5262.. which are start from "S"? Thank you so much!
4 ответов
+ 4
Jan Markus Now you've got a pesky initial space to get rid of 😁
+ 3
Try your best if you won't get then we will help you out from error! Provide us a sample code of your hardwork on it and do mention language in tag:) .
+ 1
What language? All are similar but differents way. You could use delimiter.
Java: Scanner sc = new Scanner(string);
sc.useDelimiter("S").
And regex are nice.
Regex regex =S\d+
S: look for literal "S".
\d: look for number.
+: Matches more than one number, till find the S again and be another match.
0
I will do it next time! Thanks for your help Jan & Chaithra🙏