How do I create two functions: one to put a collection of criteria into normal form, and one to compute the score of a document. A collection of criteria will be represented using an integer and three arrays. The integer is the number of criteria in the collection; the three components of each criterion are stored in the same position across the three arrays. If there are n criteria, they occupy positions 0 through n-1 of the arrays. The three arrays are
an array of ints, holding the distances
an array of C strings, holding the w1 words
an array of C strings, holding the w2 words