Relevance percentage between two string
How to get relevance percentage b开发者_如何学编程etween two string in C#?
Are you looking for something similar to the the Levenshtein distance, which is the distance between two strings is given by the minimum number of operations needed to transform one string into the other?
There's no simple answer for this, but have a look at Wikipedia's string metrics article. There are lots of different approaches, though the most widely known is probably the Levenshtein distance, which assigns an integer ranking to a pair of strings to quantify the 'distance' between them.
check out the open source package SimMetrics on sourceforge - this should cover every possible need fairly simply.
精彩评论