• 2022-07-28
    下述语句中,在字符串sl和s2相等时显示“they are Equal”的是( )。
    A: A) if(*s1==*s2)
    B: puts("they are Equal");
    C: B) if(!strcmp(s1,s2))
    D: puts("they are Equal");
    E: C) if(s1==s2)
    F: Puts("they are Equal");
    G: D) if(strcmp(s1,s2))
    H: puts("they are Equal”);
  • B

    内容

    • 0

      下列语句中,在字符串s1和s2相等时显示“they are Equal”的是( )。 A: if(*s1==*s2) B: if(!strcmp(s1,s2)) C: puts("they are Equal"); puts("they are Equal"); D: if(s1==s2) E: if(strcmp(s1,s2)) F: Puts("they are Equal"); pros("they are Equal");

    • 1

      下述语句中,在字符串s1和s2相等时显示“they are Equa1”的是()。 A: if(*s1==*s2) B: puts("they are Equa1"); C: if(!strcmp(s1,s2)) D: puts("they are Equa1"); E: if(s1==s2) F: Puts("they are Equa1"); G: if(strcmp(s1,s2)) H: puts("they are Equa1");

    • 2

      有字符数组s1[80]和s2[80],则正确的输出语句是 。 A: puts(s1,s2); B: printf("%s,%s",s1[],s2[]); C: putchar(s1,s2); D: puts(s1),puts(s2);

    • 3

      下述语句中,()可以在字符串s1和s2相等时显示"Equal."。 A: if(!strcmp(s1,s2)) puts(“Equal.”); B: if(s1==s2) puts(“Equal.”) C: if(*s1==*s2) puts(“Equal.”) D: if(strcmp(s1,s2)) puts(“Equal.”);

    • 4

      下述语句中,在字符串s1和s2相等时显示"theyareEqual"的是()。 A: if(*s1==*s2)puts("theyareEqual"); B: if(!strcmp(s1,s2))puts("theyareEqual"); C: if(s1==s2)puts("theyareEqual"); D: if(strcmp(s1,s2))puts("theyareEqual");