My apologies. I should have made it clearer, but I thought the comment "# Should only be processing each name once!" would suffice since it implies names can exist more than once. In fact, pretty much all of them exist at least twice. If they only existed once this would have been easy!!
Elda Taluta; Sarks Sark; Ark Arks