• 2022-05-28
    运行时从键盘上输入字符串Student和t,以下程序运行后的输出结果是( ) #include[stdio.h]main(){ char s1[30],s2[30]; int i,j; char c; printf("please input a string:\n"); gets(s1); printf("please input a random character:\n"); c=getchar(); for(i=0,j=0;s1[i]!='\0';i++) { if(s1[i]!=c) s2[j++]=s1[i]; } s2[j]='\0'; puts(s2);}[/i][/i][/i]