1.5. small fix
This commit is contained in:
parent
ec9303b790
commit
3c638942ec
|
|
@ -1,4 +1,4 @@
|
||||||
# 1.4. Levenshtein distance
|
# 1.5. Levenshtein distance
|
||||||
|
|
||||||
## Given two strings, check if they are one edit (or zero edits) away. Edits can be insertion, substitution or deletion
|
## Given two strings, check if they are one edit (or zero edits) away. Edits can be insertion, substitution or deletion
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -42,7 +42,6 @@ def levenshtein(s1, s2):
|
||||||
return False
|
return False
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|
||||||
class Test(unittest.TestCase):
|
class Test(unittest.TestCase):
|
||||||
dataT = [("", ""), ("an", "a"), ("a", "an"), ("ane", "ae"),
|
dataT = [("", ""), ("an", "a"), ("a", "an"), ("ane", "ae"),
|
||||||
("ane", "ne"), ("asdfgh", "asdgh"), ("asdf", "asgf")]
|
("ane", "ne"), ("asdfgh", "asdgh"), ("asdf", "asgf")]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue