Question: Using C++ a) Dynamic allocation of the memory is done on the heap. Global variables and variables local to functions are allocated memory somewhere else.
Using C++

a) Dynamic allocation of the memory is done on the heap. Global variables and variables local to functions are allocated memory somewhere else. Give a programming example (aka short part of a code) in which both static arrays and dynamic arrays are being declared and initialized to any values. b) Consider the following programming scenario: int i = 4: int *ptr1 = & i: ++i: cout
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
