C++ examples for Data Type:Array
Storing a Fixed Number of Objects using array
#include <cinttypes> #include <iostream> using namespace std; int main(int argc, char* argv[]) { const int numberOfElements{ 5 }; int32_t normalArray[numberOfElements]{ 10, 65, 3000, 2, 49 }; for (int i{ 0 }; i < numberOfElements; ++i) {/*from w w w. j a va2s .c om*/ cout << normalArray[i] << endl; } return 0; }