Tanton: I am sure we could do it in one step as this: $str =~ s/(\d\d\s*)$/$1;
Right? -- Rex > -----Original Message----- > From: Tanton Gibbs [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, January 29, 2002 4:18 PM > To: Dhiraj P Nilange; [EMAIL PROTECTED] > Subject: Re: a very simple question > > > Just put the part you want to extract in parentheses and then > set $str equal > to $1...for example: > > $str =~ /(\d\d\s*)$/; > $str = $1; >