Function stringzilla::sz::hamming_distance_utf8_bounded
source · pub fn hamming_distance_utf8_bounded<F, S>(
first: F,
second: S,
bound: usize
) -> usizeExpand description
Computes the Hamming edit distance between two UTF8 strings, counting the number of substituted variable-length characters. Difference in length is added to the result as well.
§Arguments
first: The first byte slice.second: The second byte slice.bound: The maximum distance to compute, allowing for early exit.
§Returns
A usize representing the minimum number of single-character edits (substitutions) required to
change first into second.