Home > Back-end >  C language for the answer
C language for the answer

Time:09-28

# include & lt; stdio.h>
# include & lt; String. H>
Char * fun (char * t)
{
Char * p=t;
Return (p + strlen (t)/2);
}
Int main (void)
{
Char * STR="abcdefgh";

STR=fun (STR);
Puts (STR);

return 0;
}
Abcdefgh
The abcd
Efgh
fgh

CodePudding user response:

Strlen (t) 8, so p + 4 'e' address, so the final output efgh

CodePudding user response:

Thank you very much for bosses
  • Related