in reply to Re: Building Paths without Regex
in thread Building Paths without Regex
Thank you for the quick answer! I found a typo in the first if statment while I was ensuring that I was doing everything case sensitive. Here is an example of what I was doin wrong:
if (/bar/){ $foo = substr($_, 5) } elsif (/bar/) { $bar = substr($_, 8) }
I was testing for /bar/ but adding the variable to $foo, which was messing up the first variable $var1. To answer your question, the $_ is the default value from the while loop used to read the source file. I want to apologize for not making my post clearer. I am reading data from a file using a while loop. I've been at this for 12 hours straight :) and am a little fried
|
|---|