blob: 62ff1ffc422a872440cfda8cc204bd7ce4cb286b (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
#!python
import textdistance
from sys import stdin
for line in stdin.readlines():
x,y = line.split('\t')
x = x.casefold()
y = y.casefold()
v = textdistance.ratcliff_obershelp.normalized_similarity(x,y) + textdistance.jaro_winkler.normalized_similarity(x,y) + textdistance.cosine.normalized_similarity(x,y)
print (int(100*(v/3)))
|