template <typename T, int N>
int ArraySize (T (&arr)[N]) {
//此处是数组的引用,在C语言中不支持
return N;
}
参考:https://www.cnblogs.com/fuxianfeng1988/archive/2013/08/21/3273141.html
template <typename T, int N>
int ArraySize (T (&arr)[N]) {
//此处是数组的引用,在C语言中不支持
return N;
}
参考:https://www.cnblogs.com/fuxianfeng1988/archive/2013/08/21/3273141.html