posted 14 years ago
I think, the Answer is 1. Only 'z' will be eligible for GC !!
x, y, & a links to same number, while only z is linking to null at the end.
So only z will be eligible for GC !!
Just draw a diagram, that way it will be very easy to understand !!
Thanks,
Ved