• 2021-04-14
    下列程序运行时输入:This_is_a_C_Program! 运行结果为:


    #include
    #include
    int main(void)
    {
    char str[81], a[81], b[81];
    int n, i, j=0, k=0;
    gets( str );
    n=strlen( str );
    for ( i=0; i
    {
    if ( i%2==0 ) a[j++] = str[i];
    if ( i%3==0 ) b[k++] = str[i];
    }
    a[j] = b[k] = '';
    puts( a );
    puts( b );
    return 0;
    }