下面代码片段的运行结果是 。
char a[] = "abcdef";
char b[] = "ABC";
memcpy (a, b, strlen (b) * sizeof (b[0]));
printf ("%s\n", a);
strcpy (a, b);
printf ("%s\n", a);
A.ABCABC
B.ABCdefABCdef
C.ABCdefABC
D.ABCABCdef
第1个回答 2014-08-17
下面代码片段的运行结果是 。
char a[] = "abcdef";
char b[] = "ABC";
memcpy (a, b, strlen (b) * sizeof (b[0]));
printf ("%s\n", a);
strcpy (a, b);
printf ("%s\n", a);
A.ABCABC
B.ABCdefABCdef
C.ABCdefABC
D.ABCABCdef
本站内容来自于网友发表,不代表本站立场,仅表示其个人看法,不对其真实性、正确性、有效性作任何的担保
相关事宜请发邮件给我们
© 非常风气网