get size of any type array - C++ Forum - cplusplus.com - The C++ Resources Network

get size of any type array - C++ Forum - cplusplus.com - The C++ Resources Network

瀏覽:1431
日期:2024-05-09
Does anyone know how to find the length of an arbitrary type of array? All I have found online were how to find the length of an int array. ... 1 2 3 4 5 6 7 8 9 10 11 #define ARRAY_SIZE(array) (sizeof((array))/sizeof((array[0]))) int main() { short arr_i...看更多