We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a521b46 commit fcd2346Copy full SHA for fcd2346
levenshtein.go
@@ -2,8 +2,8 @@ package kong
2
3
import "unicode/utf8"
4
5
-// https://en.wikibooks.org/wiki/Algorithm_Implementation/Strings/Levenshtein_distance#Go
6
-// License: https://creativecommons.org/licenses/by-sa/3.0/
+// Copied from https://github.com/daviddengcn/go-algs/blob/fe23fabd9d0670e4675326040ba7c285c7117b4c/ed/ed.go#L31
+// License: https://github.com/daviddengcn/go-algs/blob/fe23fabd9d0670e4675326040ba7c285c7117b4c/LICENSE
7
func levenshtein(a, b string) int {
8
f := make([]int, utf8.RuneCountInString(b)+1)
9
0 commit comments