this example creates single object containing the value is merely name that refers to the newly created object when is assigned ab becomes new name for the same object and the object' reference count increases likewisewhen you place into listthe object' reference count increases again throughout the exampleonly one object contains all other operations are simply creating new references to the object an object' reference count is decreased by the del statement or whenever reference goes out of scope (or is reassignedhere' an exampledel decrease reference count of decrease reference count of [ decrease reference count of the current reference count of an object can be obtained using the sys getrefcount(function for examplea import sys sys getrefcount( in many casesthe reference count is much higher than you might guess for immutable data such as numbers and stringsthe interpreter aggressively shares objects between different parts of the program in order to conserve memory when an object' reference count reaches zeroit is garbage-collected howeverin some cases circular dependency may exist among collection of objects that are no longer in use here' an examplea [' ' [' ' del del contains reference to contains reference to in this examplethe del statements decrease the reference count of and and destroy the names used to refer to the underlying objects howeverbecause each object contains reference to the otherthe reference count doesn' drop to zero and the objects remain allocated (resulting in memory leakto address this problemthe interpreter periodically executes cycle detector that searches for cycles of inaccessible objects and deletes them the cycle-detection algorithm runs periodically as the interpreter allocates more and more memory during execution the exact behavior can be fine-tuned and controlled using functions in the gc module (see "python runtime services"references and copies when program makes an assignment such as ba new reference to is created for immutable objects such as numbers and stringsthis assignment effectively creates copy of howeverthe behavior is quite different for mutable objects such as lists and dictionaries here' an examplea [ , , , is true is reference to lib fl ff