杭电ACM2026题

#include <stdio.h>
int main()
{
    char s[100];
    int i;
    while (gets(s))
    {
        for (i=0;i<strlen(s);i++)
        {
            if (i==0)
            {
                s[i]-=32;
            }
            else
            {
                if(s[i]==' '&&s[i+1]!=' ')
                    s[i+1]-=32;
            }
        }
        printf("%s\n",s);
    }
    return 0;
}

 

相关文章:

  • 2021-05-05
  • 2021-11-13
  • 2021-07-31
  • 2021-04-27
  • 2021-04-26
  • 2021-09-26
  • 2021-06-26
  • 2021-04-18
猜你喜欢
  • 2021-07-04
  • 2021-06-19
  • 2021-12-10
  • 2022-01-10
  • 2021-12-14
  • 2021-04-04
  • 2021-08-19
相关资源
相似解决方案