How can I search for the first divergent character in two strings? e.g. if $sa="abcdef" en $b="abcedf" then the strings differ first in position 4.
In theory I can xor the two strings and then look for the first non x00 character (if any). In practice I can't find the right Perl combination.![[ponder] [ponder] [ponder]](/data/assets/smilies/ponder.gif)
_________________________________
In theory, there is no difference between theory and practice. In practice, there is. [attributed to Yogi Berra]
In theory I can xor the two strings and then look for the first non x00 character (if any). In practice I can't find the right Perl combination.
![[ponder] [ponder] [ponder]](/data/assets/smilies/ponder.gif)
_________________________________
In theory, there is no difference between theory and practice. In practice, there is. [attributed to Yogi Berra]