(continued from previous pagesys getrefcount( [ append(rc [ sys getrefcount( garbage collection the 'delcommand decrease the value of reference countwhen this value reaches to zerothe object is garbage collected as shown belowdel sys getrefcount( del sys getrefcount( del shallow and deep copy notein section we assigned awhich created reference for as howeverthis behaviour is quite different for mutuable objects list and dictionary there are two types of reference for these cases shallow copy and deep copy shallow copy in shallow referenceinner list or dictionary shared the data between two references as shown below note thata and are not same ' is bresults as falsebut still change in results in change in [ [ ] list(acreate shallow copy [ are still shared [ [ ] is false append( no change in [ [ ] [ ][ value of is changed [ [ ] reference count and garbage collection