open my $fh, '<', $file or die "Can't read $file: $!"; #### my $start = $1; $start--; #increment down for substr my $end = $2; $end--; #increment down for substr #### sub html_out { my ( $total_muts, $mutant_genes_ref ) = @_; my %mutant_genes = %{$mutant_genes_ref}; # ...etc... }