FAQ chr convert from small to captial (C++)

This is a discussion on FAQ chr convert from small to captial (C++) within the FAQ Board forums, part of the General Programming Boards category; how would i convert a small chr at the start of a string into a capital with out converting the ...

  1. #1
    Registered User
    Join Date
    Nov 2001
    Posts
    3

    Question chr convert from small to captial

    how would i convert a small chr at the start of a string into a capital with out converting the rest of the letters after the first into capitals as well ?

    thanks newbie
    Last edited by hlens; 11-08-2001 at 05:01 PM.

  2. #2
    zen
    zen is offline
    of Zen Hall zen's Avatar
    Join Date
    Aug 2001
    Posts
    1,007
    Use toupper() - include cctype and csdtlib -

    char a[]="zen";
    a[0]=toupper(a[0]);
    zen

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Wiki FAQ
    By dwks in forum A Brief History of Cprogramming.com
    Replies: 192
    Last Post: 04-29-2008, 02:17 PM
  2. Replies: 2
    Last Post: 09-20-2006, 06:40 PM
  3. FAQ Check/Lock
    By RoD in forum A Brief History of Cprogramming.com
    Replies: 2
    Last Post: 10-15-2002, 12:21 PM
  4. FAQ how do i convert a string to an integer?? (C)
    By Unregistered in forum FAQ Board
    Replies: 1
    Last Post: 12-02-2001, 05:03 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21