You'll typically use sizeof to calculate the size you need malloc(). // allocate a 10-float array float* arr = (float*) malloc(10*sizeof(float));.
確定! 回上一頁