Page 1 of 1

simple string parsing problem

Posted: Thu May 25, 2006 1:59 pm
by mohit04
Hi ,
I need to count the number of uppercase letters in a a string.How can this be done?

Posted: Thu May 25, 2006 2:57 pm
by Oren
My suggestion:
Use regex to get rid of any thing that is not an upper case letter ([^A-Z]) and then use strlen() to get the length of the new string.