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...

Does garbage collection guarantee that a program will not
run out of memory?

Answer Posted / ranganathkini

Garbage Collection of Java is an automatic mechanism that
safeguards against memory leaks and handles memory
allocation and de-allocation.

The GC makes all possible attempts to free memory and make
it available for fresh allocations. But at certain times it
cannot. At those times, it throws an OutOfMemoryError.

So to conclude, GC handles most of the memory management and
makes all possible attempts to make memory availabe for the
application but it does not gurantee that it will be able to
provide it.

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is hashing principle in java?

1010


How do you remove duplicates from an array in java?

936


What is meant by main method?

1045


Can you extend main method in java?

1155


What is the difference between iterator and list iterator?

1017


How do you escape in java?

1048


What is jagged array in java?

1066


I want to control database connections in my program and want that only one thread should be able to make database connection at a time. How can I implement this logic?

1092


Write a program to print fibonacci series

1138


Can we override tostring method in java?

959


What is the purpose class.forname method?

946


What is a loop java?

1039


What is function overriding and overloading in java?

1101


Explain the difference between abstraction and encapsulation.

952


What is arrays fill in java?

990