You are submitting 2 parameters (2 dna sequences) to the subroutine, so in the above code which computes the hamming distance, how do you know which variable refers to which sequence? Or could you just explain what the code above is doing? Thank you so much!sub hd{ length( $_[ 0 ] ) - ( ( $_[ 0 ] ^ $_[ 1 ] ) =~ tr[\0][\0] ) }
In reply to Re^11: Comparing 2 different-sized strings
by AdrianJ217
in thread Comparing 2 different-sized strings
by AdrianJ217
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |