One approach
Use data filter advanced to extract a unique list of column B values listed vertically, and similarly a unique list of column A values listed horizontally.i.e. the row and column labels.
Now add a helper column (say D) to your original data which concatenates the A & B cells, e.g. C110440.
Now you can use =MATCH() and =INDEX() to obtain your results.
So assuming your table headers are in column F & row 1 in G2 enter
=INDEX(C:C,Match(G$1&$F2,D:D,False),1)
and copy down and across your table.
HTH
Bookmarks