标签:tar res must sum ++ address etc i+1 解释
language: C
// nt题,不解释
/**
* Note: The returned array must be malloced, assume caller calls free().
*/
int* printNumbers(int n, int* returnSize){
returnSize[0] = pow(10,n)-1;
int *ans = (int *)malloc(sizeof(int) *returnSize[0]);
for(int i = 0; i<returnSize[0];i++)
ans[i]=i+1;
return ans;
}
标签:tar res must sum ++ address etc i+1 解释
原文地址:https://www.cnblogs.com/gallien/p/14323502.html