简历二维数组的方法

来源:互联网 发布:ubuntu 文本输入设置 编辑:程序博客网 时间:2024/05/16 20:16
int** a=(int**)malloc(sizeof(int*)*rows);for (int i=0;i<10;i++){a[i]=(int*)malloc(sizeof(int)*col);}


int** a=new int*[rows];for (int i=0;i<10;i++){a[i]=new int[col];}


原创粉丝点击