B = [6, 3, 5, 3, 8, 4, 3]
Concate = dict()
for i in range(len(A)):
    if A[i] in Concate:
        Concate[A[i]] += B[i]
else:
    Concate.update({A[i]: B[i]})
C = list(Concate.keys())
D = list(Concate.values())
print(('C=', C))
print(('D=', D))
Python: how to detect duplicates in a list to signal a different operation