Pregunta de entrevista de Bloomberg

How does java garbage collection work?