Sub TotalCode()
Dim d1, d2, i As Long, T, TRes
Set d1 = CreateObject("Scripting.Dictionary")
Set d2 = CreateObject("Scripting.Dictionary")
T = Range("A2:C" & [a65000].End(xlUp).Row) ' Table entrée
For i = LBound(T, 1) To UBound(T, 1)
d1(T(i, 1)) = T(i, 2)
d2(T(i, 2)) = d2(T(i, 2)) + T(i, 3)
Next i
TRes = Application.Transpose(Array(d1.keys, d1.items, d2.items))
[E2].Resize(d1.Count, UBound(T, 2)) = TRes
End Sub