Creating an Array
In this chapter, you will see the use of arrays in C++.
We'll cover the following...
We'll cover the following...
Introduction
An array is a collection of elements of the same data type a the single name. Let’s see how we can declare and initialize an array in C++.
Array declaration
The general syntax for declaring an array is given below:
In the array declaration, we specify the data type followed by an array name, which is then followed by an array size in square brackets.
See the code given below!
We declare an array Roll_Number that can store 5 integer ...