阅读背景:

声明列表中的多个类型说明符。

来源:互联网 
#include <cs50.h>
#include <stdio.h>
#include <string.h>

int main(void)
{
    //ask user for input
    string s = get_string();

    //make sure get_string() returned a string
    if(s != NULL)
    {
        //iterate over the characters one at a time
        for(int i = 0, int n = strlen(s); i < n; i++)
        {
            //print i'th character in s
            printf("%c\n", s[i]);
        }
    }
    else
    {
        //tell the user that their input is not a string
        printf("Sorry, no good\n");
    }

}
#include <cs50.h>
#include <stdio.h>
#include <



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: