Function edit_distance::edit_distance [] [src]

pub fn edit_distance(a: &str, b: &str) -> usize

Returns the edit distance between strings a and b.

The runtime complexity is O(m*n), where m and n are the strings' lengths.

Examples

use edit_distance::edit_distance;

edit_distance("kitten", "sitting"); // => 3