1165:0 starting point algorithm 72--first letter capitalization

Source: Internet
Author: User

1165:0 starting point algorithm 72--initial capitalization time limit:1 Sec Memory limit:64 MB 64bit IO Format:%lld
submitted:705 accepted:439
[Submit] [Status] [Web Board] Description

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

Input

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

Output

Please 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 an Accepted

Source

0 Starting point Learning algorithm

1#include <stdio.h>2 intMain () {3     Chara[ -];4      while(Gets (a)! =NULL) {5a[0]+='A'-'a';6          for(intI=1; a[i]!=' /'; i++){7             if(a[i]==' ') a[++i]+='A'-'a';8         }9 puts (a);Ten     } One     return 0; A}

1165:0 starting point algorithm 72--first letter capitalization

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.