the Levenshtein algorithm provides a simple edit-distance calculation.