NorthBay interview question

How does java manage its memory?