Checking size of the array

suggest change

One of the main advantage of std::array as compared to C style array is that we can check the size of the array using size() member function

int main() {
	std::array<int, 3> arr = { 1, 2, 3 }; 
	cout << arr.size() << endl;
}

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents