NAME
srchscore - determine quality of string match

SYNOPSIS
int srchscore (big,small);
char *big,*small;

DESCRIPTION
Srchscore takes two strings, and gives you back a number which
tries to capture the idea of "how well" they match each other. The
integer returned is in the range from 0 to the square of the length
of small, with a higher score indicating a better match.

The match is determined by taking consecutive substrings of small
which match substrings of big, squaring the length of each such
substring, then imposing a penalty for not-quite-exactly-matching
corresponding substrings. These scores are added up to determine
the final score.

SEE ALSO
strcmp(3), stlmatch(3), stabsearch(3)

HISTORY
13-Nov-86 Andi Swimmer (andi) at Carnegie-Mellon University
Revised for 4.3.

23-Jan-80 Steven Shafer (sas) at Carnegie-Mellon University
Patterned after Dave McKeown’s matching function.