A:\minispir.GIFA:\minispir.GIF
‹#›
20
Constructors
•The purpose of the constructor is to initialize the data members
•So, for the dynamic array it simply allocated the array’s memory and initialized the size. What else?
•Yes, it also needs to set the number of items currently stored in the list to zero.
•Why doesn’t it need to initialize each element of the array?