$_ is a global.
Beside that to get the first parameter you passed to your subs you should use
my $line = lc $_[0]; # and $another_line = $_[0];
as it is the first element in the @_ array, which contains all arguments to the sub.
Beside that you should not use $ in sub names, you should not use & in function calls and you should use warnings.
Cheers, Flo
In reply to Re: Why is this incorrect?
by rafl
in thread Why is this incorrect?
by kettle
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |