coec has asked for the wisdom of the Perl Monks concerning the following question:
When I try and use the arraymy @Column_Info = { [ 1024, 1067 ], # Column 1 start stop [ 1068, 1093 ], # Column 2 start stop [ 1094, 1137 ], # Column 3 start stop [ 1138, 1163 ], # Column 4 start stop [ 1164, 1207 ], # Column 5 start stop [ 1208, 1233 ], # Column 6 start stop [ 1234, 1277 ], # Column 7 start stop [ 1278, 1321 ] }; # Column 8 start stop
I get the errormy $StartPos = $Column_Info{$Count->[0]}; # Slot to start at my $Pos = $StartPos; # Slot to start at my $EndPos = $Column_Info{$Count->[1]}; open(IN,"cat /tmp/show_library.$$|"); while (<IN>) { $_ =~ s/^ //; while ($Pos <= $EndPos) { if ($Pos == 1024) { <snip>
How do I correctly set up and reference this array?Use of uninitialized value in numeric le (<=) at ./show_library.pl lin +e 143, <IN> line 69. Use of uninitialized value in printf at ./show_library.pl line 140, <I +N> line 70.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Two dimensional array problem
by dpuu (Chaplain) on Jul 21, 2002 at 03:32 UTC | |
|
Re: Two dimensional array problem
by Nitrox (Chaplain) on Jul 21, 2002 at 03:39 UTC | |
|
Re: Two dimensional array problem
by flocto (Pilgrim) on Jul 21, 2002 at 09:30 UTC |