![]() |
#2
lyshyhuangli2008-11-12 13:41
|
char* str1="56789";
char* str2="123456789";
strcpy(str1,str2);
cout < <str1 < <endl;
cout < <str2 < <endl;
在debug模式下编译正常,但运行出错;
在release模式下,能正常运行;
答案是:123456789和9.
请高手们分析一下这个结果!!
在线等待……