Thread: Counting uppercase and lowercase letters in a text

  1. #1
    Registered User
    Join Date
    Oct 2007
    Posts
    11

    Unhappy Counting uppercase and lowercase letters in a text

    Can anyone help me to count the uppercase and lowercase letters in a text?

  2. #2
    Jack of many languages Dino's Avatar
    Join Date
    Nov 2007
    Location
    Chappell Hill, Texas
    Posts
    2,332
    Post the code you have so far. Tell us where you are stuck.
    Mainframe assembler programmer by trade. C coder when I can.

  3. #3
    Woof, woof! zacs7's Avatar
    Join Date
    Mar 2007
    Location
    Australia
    Posts
    3,459
    Use isupper() and islower() from ctype.h to check if the character is uppercase or lowercase.

    Hint: You'll probably have to loop through each character

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. how to detect a lowercase or uppercase char?
    By Axel in forum C Programming
    Replies: 5
    Last Post: 09-04-2005, 12:28 PM
  2. Uppercase and lowercase
    By StarOrbs in forum C++ Programming
    Replies: 4
    Last Post: 03-09-2005, 04:18 PM
  3. Replies: 14
    Last Post: 06-06-2004, 03:51 PM
  4. Uppercase & Lowercase
    By Dennis in forum C Programming
    Replies: 2
    Last Post: 11-14-2002, 08:07 AM
  5. C++ newbie..convert string from lowercase to uppercase
    By wireless in forum C++ Programming
    Replies: 5
    Last Post: 02-25-2002, 08:49 PM