my @beef = @{ $dataset->{ $col[0] } }; #### my $key = $col[0] ; my $meat = $dataset->{ $key }; my @beef = @{ $meat }; #### ## no warnings or errors $ perl -e "print @{ undef() }; print 6" 6 ## a warning is issued, but 6 still gets printed $ perl -we "print @{ undef() } Use of uninitialized value in array dereference at -e line 1. 6 ## with strict the warning is fatal, 6 not printed cause program died $ perl -Mstrict -we "print @{ undef() } Can't use an undefined value as an ARRAY reference at -e line 1. #### next unless $meat; #### push @{$data[$nr - 1]->{shift(@cols)}},\@cols; #### push @{ $data[ $nr - 1 ]->{ shift(@cols) } }, \@cols; #### push @{ $data[ $fileCount ]->{ shift @col } }, \@col; #### my $Hashref = $data[ $fileCount ]; if( not $Hashref){ $Hashref = $data[ $fileCount ] = {}; } my $key = shift @col; my $Arrayref = $Hashref->{ $key }; if( not $Arrayref ){ $Arrayref = $Hashref->{ $key } = []; } push @{ $Arrayref }, \@col; #### my $Hashref = $data[ $fileCount ]; if( not $Hashref){ my %newHashThatIsOnlyNamedHere; $Hashref = $data[ $fileCount ] = \%newHashThatIsOnlyNamedHere; } my $key = shift @col; my $Arrayref = $Hashref->{ $key }; if( not $Arrayref ){ my @newArrayThatIsOnlyNamedHere; $Arrayref = $Hashref->{ $key } = \@newArrayThatIsOnlyNamedHere; } push @{ $Arrayref }, \@col;