perl -le 'print for a .. z' | perl -nle 'if (/d/ .. /h/) { next unless // and $_ eq $&; print; }' d h