Count the occurance of upper or lower case letters

G

Guest

Is there a way to distinguish between and count the occurance of lower and
upper case letters in an array ? eg If I have a series of columns populated
with either uppercase "S" or loercase "s", can i use a formula to count the
occurance of each type ?
 
B

Bob Phillips

Sivsy,

This will count cells starting with a lower case s

=SUMPRODUCT(--(ISNUMBER(FIND("s",LEFT(A1:A18,1)))))

If you want only s, then use

=SUMPRODUCT(--(ISNUMBER(FIND("s",LEFT(A1:A18,1)))),--(LEN(A1:A18)=1))

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
K

Ken Wright

Also if you just wanted a count of all the lowercase letters regardless of
what they are, then assuming no blanks

=SUMPRODUCT(--(CODE(A1:L100)>=97))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top