You are going to get one extra hyphen because
print ( $common_letters[ $_ ] || "-" ) for ( 0 .. length $reference );
should be
print ( $common_letters[ $_ ] || "-" ) for ( 0 .. length( $reference ) + - 1 );
Cheers,
JohnGG
In reply to Re^2: Matching or masking specific characters in an array of strings
by johngg
in thread Matching or masking specific characters in an array of strings
by duggles
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |