Dynamic memory of output array

what is the use of dynamic memory allocation for output array

Hey @mohitsingh
Static memory allocation is done on stack
And stack is of limited size
Sometimes we dont know the space needed in the program and there dynamic allocation can be useful as we do it on rutime