Pointers and Arrays

copy over the files provided for you add the code described in the comments to main1.cpp add the code to perform each action directly under each comment
File: main1.cpp

/*   static arrays versus dynamic arrays      */

#include "cmpslib19.h"
#include "easylogging++.h"
INITIALIZE_EASYLOGGINGPP



void PrintArray(int*array,int size)
  {
      LOG(INFO) << "Start " <<  __PRETTY_FUNCTION__ << endl;
  cout << "Array Address" << array << endl;
  for(int loop =0; loop<size; loop++)
    {
    if(loop)
      {
      cout << ",";
      }
    cout << array[loop];
    }
  cout << endl;
      LOG(INFO) << "End " <<  __PRETTY_FUNCTION__ << endl;
  }

int main()
  {
  el::Configurations LGR;
  LGR.setToDefault();// load current configuration

  #if LOGGING ==ON
    LGR.setGlobally(el::ConfigurationType::Filename,"main1.log");// set logname

    LGR.set(el::Level::Info,el::ConfigurationType::ToStandardOutput,"false");// dont push LOG (INFO) to console

  #else
    LGR.setGlobally(el::ConfigurationType::Enabled,"false");// disable all the logging

  #endif
  el::Loggers::reconfigureLogger("default", LGR);// store new configuration








  // create a static int array of size 20 named SIntArray
// create a dynamic int array of size 20 named DIntArray

// use a for loop to populate both arrays with the values 0-19 , use the [] operator

// use the PrintArray functions to print them both out

// use a for loop to populate both arrays with the values 100-119 (loop+100) ,   do not use the [] operator

// use the PrintArray functions to print both arrays

// print out the address of the first  , second and fifth element of both arrays, use the & and [] operators

// print out the address of the first  , second and fifth element of both arrays, do NOT  use the & and [] operators

// create an int * temp

// set temp to the begining of SIntArray

// increment temp pointer by 4

//  print out the value ( address ) of temp  and the value it points to

// set temp to the begining of DIntArray

// increment the pointer by 4

//  print out the value ( address ) of temp  and the value it points to

// clean up the Dynamic array

  return 0;
  }









use the runable example as a guide
File: sample_output

SIntArray:
Array Address0x7ffc234577c0
0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19
DIntArray:
Array Address0x557119c0da40
0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19
SIntArray:
Array Address0x7ffc234577c0
100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119
DIntArray:
Array Address0x557119c0da40
100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119
SIntArray:
1st:0x7ffc234577c0
2nd:0x7ffc234577c4
5th:0x7ffc234577d0
DIntArray:
1st:0x557119c0da40
2nd:0x557119c0da44
5th:0x557119c0da50
SIntArray:
1st:0x7ffc234577c0
2nd:0x7ffc234577c4
5th:0x7ffc234577d0
DIntArray:
1st:0x557119c0da40
2nd:0x557119c0da44
5th:0x557119c0da50
temp contains the address 0x7ffc234577d0 and points to the value 104
temp contains the address 0x557119c0da50 and points to the value 104
to get a good grade
------------------
1. make sure your code compiles without warnings
2. make sure your output matches the example
3. if a comment says to do something , do it right below that comment line
4. at the VERY LEAST log the start and end of all functions