Question: 3. Pointers Arrays: initializing content Using the pointer ptrArray, you now want to write values in those integers. Use a loop to go through each

3. Pointers Arrays: initializing content Using the pointer ptrArray, you now want to write values in those integers. Use a loop to go through each element in that array, and initialize them all to 42. This is done in the main. 4. Pointers Arrays: printing Write a function that will print the elements in the array-pointer. The function should accept a pointer to an integer, and the size of this array. The function should not return anything. Here is your function prototype: void printArray(int* ptr, int nb); Your function needs to use a loop to go through all the elements in the array, and simply prints them on a new line. In the main function, call this function with your pointer ptrArray and the size given by the user.

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!