int str1[]={1,2,3,4,5,6};
int size1=sizeof(str1)/sizeof(str1[0]);
cout < <size1 < <endl;
int str2[][5]={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15};
int size2=sizeof(str2)/sizeof(str2[0][0]);
int lines=sizeof(str2)/sizeof(str2[0]);
int columns=size2/lines;
cout < < "the total number is " < <size2 < <endl;
cout < < "the line number is " < <lines < <endl;
cout < < "the column number is " < <columns < <endl;
本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请
点击举报。