Skip to content
This repository has been archived by the owner on Jul 22, 2020. It is now read-only.

Southclaws/pawn-levenshtein

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

levenshtein.inc

https://en.wikipedia.org/wiki/Levenshtein_distance

Usage

Simply add to your pawn.json and include:

{
    "dependencies": ["ScavengeSurvive/levenshtein"]
}

The function levenshtein simply takes two strings and returns a score that indicates the difference.

#include <levenshtein>

main() {
    new difference = levenshtein("these strings are similar, but not the same", "these strings ar similar, but no the same");
    printf("%d", difference);
}

Testing

To test, simply run the package:

sampctl package run

Then connect to localhost:7777.

About

Levenshtein distance package for Pawn.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages