Sumproduct not works

K

kashish

In below formula in place D1 it should come "B" but its not work why?

A B C D

1 A 2 =SUMPRODUCT(--($A$1:$A$5=C1),--$B$1:$B$5)
2 B
3 C
4 D
5 E
 
L

Luke M

Because True (or 1) multipled by a letter is an invalid math operation.

Why not just do
=LOOKUP(C1,$A$1:$B$5)
 
Top