Hi again,
I am a beginner in perl and am not able to work this out. In the following string
"05/27/05 03:03:30 ANS1802E The dir is '/usr' and there are 23 files"
I want to be able to push the /usr to an array.
I am not sure how to use the search pattern in perl.
Your regex can small like this(be sure the string you need is inside ' ' as you shown us).......but all of them do the same job.....so its your choise.
#!/usr/bin/perl -w
use strict;
my @match;
while(<>){
push (@match,$1) if /'(.*)'/;
}