Assuming your data is higher in A2: B13, this works:
=MAX(IF(A2:A13="A",1,0)*(B2:B13)) =MAX(IF(A2:A13="B",1,0)*(B2:B13)) =MAX(IF(A2:A13="C",1,0)*(B2:B13))
You need to press ctrl + shft + Enter when you enter the formula into the cell. This finds all lines with A , B or C and multiplies 1 with the value next to it if the letter matches your formula, and 0 if it does not match. Then you take the MAX() values.
<<<Change β>
As @GSerg suggested, you can also do this using these formulas if you press ctrl + shft + Enter while entering them in each cell:
=MAX(IF(A:A="A",B:B)) =MAX(IF(A:A="B",B:B)) =MAX(IF(A:A="C",B:B))
A more elegant way to do it!
James L.
source share