Help for this page
use strict; use warnings; my $str='ABC---DR----EEEEEGGGG-GRE-RED----KKKK---'; my $len_seq = () = $str =~ /[^-]/g;
perldoc -q count