Memory Management in Java: Mark Sweep Compact Copy algorithm

Any garbage collection algorithm has three basic steps:

Find all objects that has the possibility of being used in future (called Mark Phase)


This is a companion discussion topic for the original entry at http://iq.opengenus.org/memory-management-in-java-mark-sweep-compact-copy/