RE: how to extract digit from a line in Perl

2004-07-14 Thread Bob Showalter
Franklin wrote: > Hello: > > I want to extract the digit from a line of text. For exmple, for a > text line: TSC2101Net, how can I write a script to extract 2101 and > print it? Use a regex to capture a series of digits: $_ = 'TSC2101Net'; my ($num) = /(\d+)/; print "Found $num\n" if def

Re: how to extract digit from a line in Perl

2004-07-14 Thread iko
Franklin wrote: > Hello: > I want to extract the digit from a line of text. For exmple, for a > text line: TSC2101Net, how can I write a script to extract 2101 and > print it? > Thank you very much in advance! > Bestwishes > Franklin > > > > >

RE: how to extract digit from a line in Perl

2004-07-14 Thread NYIMI Jose (BMB)
Title: Message   -Original Message-From: Franklin [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 14, 2004 12:01 PMTo: [EMAIL PROTECTED]Subject: how to extract digit from a line in Perl Hello:   I want to extract the digit from a

Re: how to extract digit from a line in Perl

2004-07-14 Thread David Dorward
On 14 Jul 2004, at 11:00, Franklin wrote: I want to extract the digit from a line of text. For exmple, for a text line: TSC2101Net, how can I write a script to extract 2101 and print it? There are number of techniques that spring to mind, the obvious being regular expressions and substring. The

how to extract digit from a line in Perl

2004-07-14 Thread Franklin
Hello:   I want to extract the digit from a line of text. For exmple, for a text line: TSC2101Net, how can I write a script to extract 2101 and print it?   Thank you very much in advance!   Bestwishes Franklin       IncrediMail - Emai