Hi,
String s= "
[12/22/09 22:23:57:357 MST] Some junk text that I am not interested in or not required. There is/are 10 more junk text"
From the above string, I would like to extract the time (stuff between []) and the number (10 in this case) that would look like this;
[12/22/09 22:23:57:357 MST] 10
I tried using the RE
\[.*\]|\s\d\d?\s, but the problem is I get
[12/22/09 22:23:57:357 MST] when I use
\[.*\] and
10 when I use
\s\d\d?\s, but when I combine them with a "|", I get only the date. I tried searching forums in vain, but am stuck. Any help is appreciated.