|
Posted by vunet.us on May 17, 2007, 9:11 am
Please log in for more thread options
> vunet...@gmail.com wrote:
> > How can I strip this line with regular expession to get 12345 number
> > within brackets:
>
> > $line = "some text is here (12345 ms)";
>
> > This did not work:
>
> > $text = $line;
> > $text =~ m/\((\d+)\)/;
>
> $text =~ m/\((\d+)[^\)]*\)/;
> or
> $text =~ m/\((\d+).*?\)/;
>
> HTH
>
> Tim
Thanks Tim.
I posted the question again because there were a few hours of delay
for my post to show up.
|