c++中如何在数组作为函数形参后,如何获取数组长度?

日期:2016-05-06 15:57:48 人气:1

c++中如何在数组作为函数形参后,如何获取数组长度?

#include #include using namespace std; typedef int arrT[10]; arrT* copy(arrT &arr){ int (*p)[10]=&arr; printf("Arr's address:%p\n",arr); printf("P's address:%p\n",p); return p; } int main(int argc,char *
    A+
热门评论