Sophie

Sophie

distrib > Mandriva > 2010.1 > i586 > by-pkgid > dbb2c2a2eae667c715b0455fa8a7c52f

perl-String-Similarity-1.40.0-1mdv2010.0.src.rpm

Description:

$factor = similarity $string1, $string2, [$limit]

The similarity-function calculates the similarity index of its two arguments. A
value of 0 means that the strings are entirely different. A value of 1 means
that the strings are identical. Everything else lies between 0 and 1 and
describes the amount of similarity between the strings.

It roughly works by looking at the smallest number of edits to change one
string into the other.

You can add an optional argument $limit (default 0) that gives the minimum
similarity the two strings must satisfy. similarity stops analyzing the string
as soon as the result drops below the given limit, in which case the result
will be invalid but lower than the given $limit. You can use this to speed up
the common case of searching for the most similar string from a set by
specifing the maximum similarity found so far.

Generated packages:

Other version of this rpm: