Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

how exactly garbage collection take place?

Answer Posted / vijayakumar chinnasamy

Variable/object
1. is eligible for garbage collection when no object refers
to it.
2. Is eligible when its reference is set to null i.e
objName=null.
3. referred by method variables or local variables are
eligible for garbage collection when they go out of scope.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can a main method be declared final?

1001


What is the size of int in 64-bit jvm?

1011


How do you reverse a string in java?

1057


Can we use static class instead of singleton?

999


explain local datetime api in java8?

966


Where are the local variables stored?

1016


What are the rules for naming an array?

990


Which class is the superclass for all the classes?

974


Write a program to print 15 random numbers using foreach of java 8?

889


What is the difference between state-based unit testing and interaction-based unit testing?

883


How is treeset implemented in java?

954


Can you make a constructor final?

978


What is t type java?

1010


What is outofmemoryerror in java?

966


What is multithreading in java?

1003