Sub test()
Dim dd, dc, i As Long, clef, elem
Set dd = CreateObject("scripting.dictionary")
Set dc = CreateObject("scripting.dictionary")
For i = 2 To 15
clef = Cells(i, 1)
dd(clef) = dd(clef) + Cells(i, 2)
dc(clef) = dc(clef) + Cells(i, 3)
Next i
Range("f:h").Clear
Range("a1:c1").Copy Range("f1")
Range("f2").Resize(dd.Count) = Application.Transpose(dd.keys)
Range("g2").Resize(dd.Count) = Application.Transpose(dd.items)
Range("h2").Resize(dd.Count) = Application.Transpose(dc.items)
Range("g2:h2").Resize(dd.Count).Replace 0, "", lookat:=xlWhole
Range("a2:c2").Copy...