• Post Reply Bookmark Topic Watch Topic
  • New Topic

ME-Q45(Mala Gupta)  RSS feed

 
Nil. Hatamova
Ranch Hand
Posts: 32
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need explanation for this question?
The answer is d,e
But i dont have any idea why ?
a At least two objects are garbage collected on line 1.
b At least one object is garbage collected on line 1.
c No objects are garbage collected on line 1
d The number of objects that are garbage collected on line 1 is unknown.
e At least two objects are eligible for garbage collection on line 2.
 
Roel De Nijs
Sheriff
Posts: 11338
177
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Nil. Hatamova wrote:But i dont have any idea why ?

Have a look at this topic. It's about exactly the same code snippet. So carefully read this topic and if you still have questions/doubts let us know by clicking on the "Post Reply" button.

Hope it helps!
Kind regards,
Roel

 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!