[单选题]

下列程序的运行结果为includevold abc(char*str){int a,b; for(a=b=0;str[a]!='/0';a£«

下列程序的运行结果为 #include<stdio.h> vold 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';} void main() { char str[]="abcdef"; abc(str); printf("str[]=%s",str);}

A.str[]=abdef

B.str[]=abcdef

C.str[]=a

D.str[]=ab

参考答案与解析:

相关试题

下列程序的运行结果为#includevoid abc(char*str){int

[单选题]下列程序的运行结果为includevoid abc(char*str){int a,b;for(a=b=0;str[a]!='/0';a£«£«下列程序的运行结果为 #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';} void main() { char str[]="abcdef";

  • 查看答案
  • 下列程序的运行结果为()。#includevoid abc(char*str){

    [单选题]下列程序的运行结果为()。includevoid abc(char*str){int a,b,i,j; for(i=j=0;str[i]!=下列程序的运行结果为( )。 #include<stdio.h> void abc(char*str) { int a,b,i,j; for(i=j=0;str[i]!='/0';i++) if(str[i]!='a') str[j++]=str[i]; str[j]='/0'; } void main() { char str[]="abcd

  • 查看答案
  • 下列程序的运行结果为#includevoid abc(char * str){

    [单选题]下列程序的运行结果为includevoid abc(char * str){ int a,b;for(a=b=0;str[a]!='/0';下列程序的运行结果为 #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';} void main() { char str[]="abcdef";

  • 查看答案
  • 下列程序的运行结果为()。 #include voidabc(Char*str)

    [单选题]下列程序的运行结果为()。 include voidabc(Char*str) {inta,b,i,j; for(i=j=0;str[i]!下列程序的运行结果为( )。#include<stdio.h>voidabc(Char*str){ inta,b,i,j;for(i=j=0;str[i]!='/0';i++)if(str[i]!='a')str[j++]=str[i];str[j]='/0';}void main(){ char str[]="abcdef";abc(str

  • 查看答案
  • 下列程序的运行结果为()。#includevoidabc(char*str){i

    [单选题]下列程序的运行结果为()。includevoidabc(char*str){int a,b,i,j;for(i=j=0;str[i]!='/下列程序的运行结果为( )。#include<stdio.h>voidabc(char*str){int a,b,i,j;for(i=j=0;str[i]!='/0';i++)if(str[i]!='a')str[j++]=str[j];str[j]='/0';}void main(){char Str[]="abcdef';abc(str

  • 查看答案
  • 下列程序的运行结果为()。 #include voidabc(char*str)

    [单选题]下列程序的运行结果为()。 include voidabc(char*str) {int a,b,i,j; for(i=j=0;str[i]下列程序的运行结果为( )。#include<stdio.h>voidabc(char*str){int a,b,i,j;for(i=j=0;str[i]!='/0';i++)if(str[i]!='a')str[j++]=str[j];str[j]='/0';}void main(){char Str[]="abcdef';abc(str)

  • 查看答案
  • 下列程序的输出结果是______。char*fun(char*str,int n

    [单选题]下列程序的输出结果是______。 char*fun(char*str,int n) { int i; char*p=str; for(i=0;i<10;i++,str++) *str='a'+i; return++p; } main() { char a[10]; printf("%s/n",fun(a,10)); }A.ABCDEFGHIJB.abcdefghijC.bcdefghijD.不确定的值

  • 查看答案
  • 下面程序段的运行结果是char str[]="ABC",*p=str;print

    [单选题]下面程序段的运行结果是char str[]="ABC",*p=str;printf("%d\n",*(p+3));A.67 B.0 C.字符’C’的地址 D.字符’C’

  • 查看答案
  • 下面程序段的运行结果是 char str[]="ABC",*p=str; pri

    [单选题]下面程序段的运行结果是char str[]="ABC",*p=str;printf("%d/n",*(p+3));A.67B.0C.字符′C′的地址D.字符′C′

  • 查看答案
  • 下面程序段的运行结果是 char str[]="ABC",*p=str; pri

    [单选题]下面程序段的运行结果是char str[]="ABC",*p=str;printf("%d/n",*(p+3));A.67B.0C.字符′C′的地址D.字符′C′

  • 查看答案
  • 下列程序的运行结果为#includevold abc(char*str){int