Evaluate boolean values as 1 or 0

  • Thread starter Thread starter hmm
  • Start date Start date
H

hmm

How do I use boolean values so that a formula would evaluate TRUE as 1 and
FALSE as 0? For example, if column A contains boolean values, I want to
avoid formulas like {SUM(IF(A1:A100, 1, 0))}. Instead, I would like to just
enter {SUM(A1:A100)}. Presently, in such a formula both TRUE and FALSE are
treated as 0.
 
In addition to the other replies, you can:

force the formulas that evaluate to to TRUE or FALSE to evaluate to 1 or 0
by multiplying the result by 1, or use

=SUMPRODUCT(a1:a100*1)
 
Back
Top