while ( ) { chomp( $_ ); #get rid of whitespace at end @f = split( /\s/, $_ ); #split data up into an array #ThreeDHash[ GROUP ][ PROJ ][ MONTH ] = DATA $ThreeDHash{ $f[0] }{ $f[1] }{ $f[2] } = $f[ 4 ]; } #### #same as a hash, only with square brackets # dont forget $index1/2/3 all have to be integers # so you will have to index every entry to the file. $ThreeDArray[ $index1 ][ $index2 ][ $index3 ] = $DATA;