It will be specific to the formula, but in the example you gave you can improve its efficiency and shorten it by using this instead:
Code:
=SUM(COUNTIF(E3:E5,{"d","v"}))
By the way, in your Sumproduct formula, because you are adding the Boolean result arrays, you don't need the negation:
Code:
=SUMPRODUCT((E3:E5="d")+(E3:E5="v"))