Question: C++ please Given the function prototype defined below, write the function definition to copy the first array, src, into the second, dest, in reverse order

C++ please

  1. Given the function prototype defined below, write the function definition to copy the first array, src, into the second, dest, in reverse order (so the last element of source, is the first element of dest.) You may use index notation (array-style indexing), but will receive +10 pts extra credit if you use the pointer arithmetic-based offset notation instead. If you use both, Ill raise it to +15.

void ReverseArrayByPtr(int *src, int *dest, const int SIZE);

int main()

{

const int SIZE = 7;

int input[SIZE] = { 13, 1, 17, 42, 50, 23, 34 };

int output[SIZE];

ReverseArrayByPtr(input, output, SIZE);

}

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!