The similarity between each word in the question and each word in the answer was then calculated and the sum of the closest matches gave the overall similarity.
given two sets Q and P, where Q={qw 1 ,qw 2 ,…,qw n } and P={pw 1 ,pw 2 ,…,pw m }, the similarity between Q and P is given by 1<p<n Argmax m similarity( qw p , pw m ) The function similarity( w 1 , w 2 ) maps the stems of the two words w 1 and w 2 to a similarity measure m representing how semantically related the two words are; similarity( w i , w j )< similarity( w i , w k ) represents the fact that the word w j is less semantically related than w k in respect to the word w i .