Bonsoir,
une solution via une macro
Sub aargh()
For i = 1 To Cells(Rows.Count, 1).End(xlUp).Row
dc = Cells(1, Columns.Count).End(xlToLeft).Column
If dc < 4 Then dc = 3
Set re = Range(Cells(1, 3), Cells(1, dc)).Find(Cells(i, 2))
If Not re Is Nothing Then
nl = Cells(Rows.Count, re.Column).End(xlUp).Row + 1
Cells(nl, re.Column) = Cells(i, 1)
Else
dc = dc + 1
Cells(1, dc) = Cells(i, 2)
Cells(2, dc) = Cells(i, 1)
End If
Next i
End Sub