in reply to Re: regex problem (again)
in thread regex problem (again)

Hi sweepy, Just replace S (upper case) with s (lower case)
$input = "xxxx aaaa bbbbb"; ($txt) = $input =~ /\s{5}(.+)(?{length($input);})/; chomp; print $txt;
This is working!

Replies are listed 'Best First'.
Re^3: regex problem (again)
by JavaFan (Canon) on Apr 30, 2012 at 15:11 UTC
    No, it's not:
    my $input = "xxxx aaaa bbbbb"; my ($txt) = $input =~ /\s{5}(.+)(?{length($input);})/; print $txt, "\n"; __END__ Use of uninitialized value $txt in print at ?? line ??.