MeridianLink interview question

How is memory handled in Java?