how to find array size
C++ (programming language) with 780+ answers. Depends on the type of the array. The C++ arrays (from the header <array>) have the member function size: #include <array> #include <iostream> int main() { std::array<int, 10> a; std::cout << a.size() << '\n'; // prints 10 }. The C arrays keep their size as part of their type (just like C++ arrays actually), but as they are non-class types, they have no member functions.