in reply to Take digits from a string

Hello Monks, I have a simple doubt, can anyone pls answer me?

Yes, you can answer this yourself in about 1 minute by reading perlintro or perlrequick, and probably perlfaq or perlmonks

 [digit string] digit string -> Number of digits at the end of the string

#!/usr/bin/perl -- use strict; use warnings; use Data::Dump; use Carp::Always; use Regexp::English; my $string = "nPqwe=2456fnraqe=13910feoption"; my $rex = Regexp::English -> remember -> digits -> end ;;;; print "$rex\n"; while( $string =~ m{$rex}g ){ print "$1\n"; } __END__ (?^:(\d+)) 2456 13910