Why must you use the use this sequence of statements when removing a node from a linked implementation of an ADT List?
curPtr->setNext( nullptr );
delete curPtr;
curPtr = nullptr ;
Even though it is not part of the chain of the list, it still exists in memory and require storage space. The program would no longer be able to access this memory. This is called a memory leak.
Computer Science & Information Technology
You might also like to view...
The _______________ format is shorthand for representing strings of ones and zeros.
A. alphanumeric B. hexadecimal C. exponential D. matrix
Computer Science & Information Technology
By default, a browser displays each _________ element on a new line.
Fill in the blank(s) with the appropriate word(s).
Computer Science & Information Technology