def get_ratio(old, new):
 if (not all([old, new])):
  return VERSIONING_RATIO
 return (levenshtein_distance(old, new) / (len(old) / 100.0))

def get_ratio ( old , new ) : if ( not all ( [ old , new ] ) ) : return VERSIONING_RATIO return ( levenshtein_distance ( old , new ) / ( len ( old ) / 100.0 ) )
return a "similiarity ratio" representing the similarity between the two strings where 0 is equal and anything above less than equal .