in reply to Printing Hash of Arrays
BTW this bit of code doesn't do what you think it does
push @{ $hash_of_chroms{$chr} }, $coord unless defined $hash_of_chroms{$chr}[$coord]; # don't add +duplicates
push adds the item to the end of the list and you check some list element off in the far distance.
i.e. if the array is empty and $coord = 50, then your code does this:-
$array[0] = $coord unless $array[50];
|
|---|