Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Re: big job, starting with little scriptby muba (Priest) |
on Jul 15, 2010 at 08:02 UTC ( [id://849724]=note: print w/replies, xml ) | Need Help?? |
Try to find out where you put the line after reading from the file. Is it in $line (as $line = <FILE>) would suggest? Or is it in $_, where you seem to think it is, judging by your use of chomp with no further arguments and thusly implying chomp $_. And even more explicitely in the part where you try to print "$map($_)"; That print statement brings us to another point - you're using parens here, not accolades, or curly braces. Keep an eye out for that kind of typo :) The interesting thing is that neither answer is true, as has been pointed out above me, due to you slurping in the entire file before the while loop. But I'd like to point out something else as well. I don't mean to discourage you but I think your approach deserves some further thought. Tomato: fruit or veggie?
In Section
Seekers of Perl Wisdom
|
|