Solution Review: Dynamically Allocate Space for Two Structures
Understand how to dynamically allocate memory for two structures using pointers and malloc in C. This lesson reviews typecasting void pointers returned by malloc to specific struct pointers and managing memory on the heap.
We'll cover the following...
We'll cover the following...
Solution
See the code given below!
Explanation
p1 and p2 are pointers that are ...