Check out example codes for "how to make a array in c++". It will help you in understanding the concepts better.

Code Example 1

// Array declaration by specifying size and initializing 
// elements 
int arr[6] = { 10, 20, 30, 40 } 
  
// Compiler creates an array of size 6, initializes first 
// 4 elements as specified by user and rest two elements as 0. 
// above is same as  "int arr[] = {10, 20, 30, 40, 0, 0}"

Code Example 2

int baz [5] = { };

Code Example 3

void initarr(int arrgender[TOT_MALE][TOT_FEMALE])
  {
      for(int a =0; a < TOT_MALE;a++)
      {
          for(int b = 0; b < TOT_FEMALE;b++)
          {
              arrgender[a][b] = 0;
          }
      }

Code Example 4

// datatype var_name[howmuch value you need to store] = {values, values}
int a[5] = {1, 2 3, 4, 5};

Learn ReactJs, React Native from akashmittal.com