UtilStringGetSimilarity Method
Computes the similarity percentage between two strings, by using the Levenshtein algorithm.
Namespace: DevCase.Core.DataProcessing.CommonAssembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
public static double GetSimilarity(
string first,
string second
)
Public Shared Function GetSimilarity (
first As String,
second As String
) As Double
Dim first As String
Dim second As String
Dim returnValue As Double
returnValue = UtilString.GetSimilarity(first,
second)
public:
static double GetSimilarity(
String^ first,
String^ second
)
static member GetSimilarity :
first : string *
second : string -> float
No code example is currently available or this language may not be supported.
- first String
-
The first string to compare.
- second String
-
The second string to compare.
Double
The similarity percentage between the two strings.
A value of 1 means the two strings are equal.
A value of 0 means the two strings have no similarity between.
This is a code example.
No code example is currently available or this language may not be supported.
Dim first As String = "Boy"
Dim second As String = "Toy"
Dim similarity As Double = GetSimilarity(first, second)
Console.WriteLine($"{NameOf(similarity)}: {similarity}")
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.