Algorithm

The algorithm returns:

  • an exception if either argument is null (Score catches and handles this)
  • 0.0 if both strings are of length 0
  • a normalized float (between 0.0 and 1.0) be doing the following:
    1. determine the max length of the two strings
    2. evaluate the two strings using the Levenshtein Edit Distance algorithm
    3. normalize the distance by evaluating ((maxLength - levDist)/maxLength)
  • No labels