you want that to be:

        $strip =~ /\w+/;  #??

see the ~ thingie

-----Original Message-----


I'm running perl version 5.005_03 and I have a simple
match and capture that I can't seem to get to work.

while (<TEMP>) {

        $strip = /\w+/;
        print "$strip \n";
}

This just returns to me a 1. Which makes sense to an
extent, for if the match is found then it will return
a 1 for "true". But I'm looking for the actual contents 
of the match, which I know will only be the first 13 
characters of the string or the first word before 
whitespace, not just whether or not it is found a match.

I found a split function and now I got it to work but 
I still would like to know how to do the above using 
a match/substitute call.




-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to