Skip to content

Combination algorithm for typo (misspelling) in Arabic and Persian language

License

Notifications You must be signed in to change notification settings

Vajehyab/combination

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 

Repository files navigation

#Demo

What is combination?

In mathematics, a combination is a way of selecting items from a collection, such that (unlike permutations) the order of selection does not matter. In smaller cases it is possible to count the number of combinations. read more

I need to test this function more then your feedbacks are appreciated, please fill an issue for any bugs you find or any suggestions you have.

How does this function sort the array?

I used the levenshtein function to sort the array, the Levenshtein algorithm (also called Edit-Distance or Levenshtein distance) is a string metric for measuring the difference between two sequences. Informally, the Levenshtein distance between two words is the minimum number of single-character edits (i.e. insertions, deletions or substitutions) required to change one word into the other. It calculates the least number of edit operations that are necessary to modify one string to obtain another string.read more

How to use this function?

   $array_1 = combination ($your_word);
   
   //Sorting by Levenshtein distance
   $array_2 = combination($your_word, 'levin');
 
 

About

Combination algorithm for typo (misspelling) in Arabic and Persian language

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages