I know there is no such thing as a virtual copy constructor but the text im reading simulates that using a clone function. I just have a question regarding the last part of the code during its cleanup of the memory. I will list the working code below. what im asking about is in main function.
Both of these arrays have automatic storage duration (i.e. you are not using 'new' to create these arrays). You should not call delete on the arrays themselves.
In each element of the array, you are assigning it a pointer to dynamic memory,
e.g. myFishes = new Tuna();
These individual elements need to be cleaned up with delete, so you need to do delete myFishes[index];
No. Even if the array where dynamically created using new all elements of that array are not destroyed when the array is destroyed. You need to delete the elements of the array with that for loop none the less.