I need to initialize $old_key to prevent a warning when reading the first line of the file.my $old_key = ""; while (<>) { my $key = (split /;/, $_)[2] next if $key eq $old_key; # ... }
In reply to Re: declare and init a scalar
by Laurent_R
in thread declare and init a scalar
by fionbarr
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |