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
Get step-by-step solutions from verified subject matter experts
