first, second, third = [set(elf) for elf in group] | first, second, third = [set(elf) for elf in group] | ||||
debug(first, second, third) | debug(first, second, third) | ||||
debug(first & second & third) | debug(first & second & third) | ||||
common_item = list(first.intersection(second, third))[0] | |||||
common_item = list(first & second & third)[0] | |||||
values.append(ascii_letters.index(common_item)+1) | values.append(ascii_letters.index(common_item)+1) | ||||
print(sum(values)) | print(sum(values)) |