• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Count non prime numbers only

jsk_lge

New Member
I have many numbers in a colum. I want to count only those numbers which are divisible by 2.
which formula should I use?
 
You can use following formula , replace B4:B79 with the range for which you want to check.

=SUMPRODUCT(--IF(MOD(B4:B79,2)=0,1))

This being an array formula , dont forget to press ctrl+Shift+enter.
 
Your posts Title and Inside Question are not totally compatible
The title "Count non prime numbers only"
implies to count non-prime numbers only

Although all Even Numbers aren't Prime

Many OddNumbers aren't prime as well,
eg: 9, 15, 21, 25, 27 etc

Just thought I'd check?
 
Back
Top