Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Getting rid of dup code #15

Merged
merged 2 commits into from
Dec 31, 2022
Merged

Fix: Getting rid of dup code #15

merged 2 commits into from
Dec 31, 2022

Conversation

notalfredo
Copy link
Member

Fixes #9

I had a different approach let me know what you think. For levenshtein distance I converted the matrix computations functions as a helper function. Then diff and distance call this helper function. This way we don't have any dupe code. Hamming works similar.

On hamming.rs line 4 I added that unnecessary line. Ill fix it after I get feedback from the code.

Fixes #9

I had a different approach let me know what you think. For levenshtein distance I converted the matrix computations functions as a helper function. Then diff and distance call this helper function. This way we dont have any dupe code. Hamming works similar
src/hamming.rs Outdated Show resolved Hide resolved
src/levenshtein.rs Outdated Show resolved Hide resolved
src/levenshtein.rs Outdated Show resolved Hide resolved
@neoncitylights neoncitylights merged commit 5d35501 into main Dec 31, 2022
@neoncitylights neoncitylights deleted the Fixing-issue-9 branch December 31, 2022 04:06
This was referenced Dec 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Duplicate code between diff() and distance()
2 participants