No such thing as a small change | |
PerlMonks |
Re: Comparing string charactersby choroba (Cardinal) |
on Nov 22, 2021 at 16:42 UTC ( [id://11139027]=note: print w/replies, xml ) | Need Help?? |
It seems like you're interested in the edit distance. There are several different algorithms, and the most well-known is Levenshtein distance, implemented for example by Text::Levenshtein.
map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]
In Section
Seekers of Perl Wisdom
|
|