Pet*_*ung -4 c malloc pointers
当你在C中声明静态变量时,
说你写了这样一个程序:
int *c;
void foo(){
c = (int *) malloc (10*sizeof(int));
c = &c[3];
*c = *&c[3];
}
Run Code Online (Sandbox Code Playgroud)
有什么意义*c?我的意思是我理解这*意味着它指的是什么,但*c做了什么?
而且,为什么需要转换(int *)返回值malloc()?