题目内容

试题6:
void GetMemory(char **p, int num )
{
*p = (char *) malloc(num );
}
void Test(void )
{
char *str = NULL;
GetMemory(&str, 100 );
strcpy(str, "hello" );
printf(str );

查看答案
更多问题

试题8:请说出static和const关键字尽可能多
的作用

试编写函数判断计算机的字节存储顺序是开序
(little endian)还是降序(bigendian)

找错题
试题1:
void test1()
{
char string[10];
char* str1 = "0123456789";
strcpy(string, str1 );
}

下面的代码有什么问题?并请给出正确的写法。

答案查题题库