def METHOD_NAME(self, list1, list2):
    scores = []
    matched = []
    for idx1, item1 in enumerate(list1):
        for idx2, item2 in enumerate(list2):
            p1, v1 = item1
            p2, v2 = item2
            score = self.criteria(v1, v2)
            if score is not 0:
                if idx1 not in matched and idx2 not in matched:
                    matched.extend([idx1, idx2])
                    scores.append(score)
                else:
                    if idx1 in matched:
                        idxScore = matched.index(idx1)
                    elif idx2 in matched:
                        idxScore = matched.index(idx2)
                    id2Replace = math.floor(idxScore/2)
                    oldscore = matched[id2Replace]
                    if score > oldscore:
                        matched[id2Replace] = score
                        matched[id2Replace*2] = idx1
                        matched[id2Replace*2+1] = idx2
    return scores