Create commonPrefixBetweenStrings