Questrade Interview Question

How does garbage collection work?