MATLAB: How to find the corresponding value

correspondMATLAB

Hello,
a = [ 1 2 3 6 8 4 ]
b = [10 11 12 13 14 15]
maxa= max(a)
bb = 14;
in this case, I want to find bb which correspond to the maximum value of a.
(because 'max(a)' located in the fifth, so I want to indicate the fifth value of the 'b')
how to do it?

Best Answer

[Max, Where] = max(a);
b(Where)
Related Question