Question: in c++ Write a function called createField that takes an integer N as the parameter and returns a pointer to a 2 dimensional dynamic array

in c++ Write a function called createField that takes an integer N as the parameter and returns a pointer to a 2 dimensional dynamic array of integers. In the function, create a 2 dimensional dynamic array of integers with N rows and N columns and set all the elements to 0. Return this array.

this is what i have to create the array

int ** arr = new int * [N]; for(int i=0; i                                            

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!