Exercise 1.15. (An Immutable Object)
1. Ensure you have viewed the video (associated with this exercise) at this link >>
2. Draw a sequence of diagrams showing the 'execution space' (as represented in the video) when the following lines of code execute.
3. Make sure you show, in one of the diagrams of the sequence, the garbage collection of an appropriate object.
4. Describe what is meant by immutable.
5. What is achieved by garbage collection?
END Next Exercise >>