• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

problem in gc

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all, this question is from examlab

can ayone please tell me how before line 12 the object eligible for gc is 1

can you also show the way how solve the general gc problem pictorially?
THANKS IN ADVANCE
 
Ranch Hand
Posts: 83
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Please note that ExamLab is famous among the ranchers here, so before you post a question about ExamLab next time try to perform a quick search to see if someone else has asked the same question before you. A quick search has led me to the same question you are asking and it was asked already by someone else, please go to the link below for an answer to your GC question.

webpage

Cheers!!!

 
Ranch Hand
Posts: 73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
This is the a graphical solution for a such kind of questions. Numbers above the arrows are code lines.



P.S.
Thanks to Devaka Cooray for this amazing SCJP simulator. I've passed it all, it's a real brainer!
 
Marshal
Posts: 6329
1094
IntelliJ IDE jQuery Eclipse IDE Postgres Database Tomcat Server Chrome Google App Engine
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Andriy Pererva wrote:Thanks to Devaka Cooray for this amazing SCJP simulator. I've passed it all, it's a real brainer!



You're very welcome Andriy
 
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@ Andriy : Thank you very much for nice explanation. It's helping me a lot to solve such problems related to GC !!

But i got confused for the code mentioned below :




It belongs to the Exercise of chapt 3..qus 11.

I created the diagram, and i realized that
b1 and a1 eligible for GC !!
But, i am not sure because answer is 1.

Can you please give a diagram, for this problem !!

Thanks in Advance !!

 
Sheriff
Posts: 9643
42
Android Google Web Toolkit Hibernate IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ved since your problem is related to a different question, so start a new topic for your question...
 
ved dixit
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi Ankit,

I will do that.

Thanks
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!