Capitalize the initial letter

Source: Internet
Author: User

Capitalize the initial letterTime limit:2000/1000 MS (java/others) Memory limit:65536/32768 K (java/others)
Total submission (s): 32066 Accepted Submission (s): 17876


problem DescriptionEnter an English sentence and change the first letter of each word to uppercase.

InputThe input data contains multiple test instances, each of which is a line of English sentences with a length of not more than 100.

OutputPlease output the English sentences that have been rewritten as required.

Sample Input
I like ACMI want to get an accepted

Sample Output
I like AcmI want to Get a Accepted  Source code:#include <stdio.h> #include <string.h>#  Include <stdlib.h>int main () {int i;  Char str[101]; while (gets (str)) {for (I=0;i<strlen (str); i++) if (i==0| |      str[i-1]== ') printf ("%c", str[i]-32);    else printf ("%c", Str[i]);  printf ("\ n");  } system ("Pause"); return 0;}

Capitalize the initial letter

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.