题库 软件开发 题目列表 下述程序的运行结果为() #include<stdio.h>...
单选题
下述程序的运行结果为()
#include<stdio.h>
void abc(char*str) {
    int a, b;
    for(a = b = 0; str[a] != '\0'; a++)
    if(str[a] != 'c')
    str[b++] = str[a];
    str[b] = '\0';
}
int main() {
    char str [] = "abcdef";
    abc(str);
    printf("str[]=%s", str);
}


A.

str[]=abdef

B.

str[]=abcdef

C.

str[]=a

D.

str[]=ab

题目信息
校招真题
-
正确率
0
评论
20
点击