levenshtein
levenshtein copied to clipboard
Minor improvements, shorten + coding style
Commit messages say it all really:
- Rename snake_cased variables to the preferred camelCase style
- Remove redundant variables, use in-place reassignments
- replace first loop with range + initialise
column[0]
outside of loop instead of reassigning - simplified the
min
implementation (possible because it's not using varargs) - added a couple of comments for clarification
- added test cases for empty strings
- exported function docs should start with the function name (for godoc)