table shows various operations that can be performed on both sets and frozensetsitem len(ss copy( difference(ts intersection(ts isdisjoint(ts isubset(ts issuperset(ts symmetric_difference(ts union(ttable methods and operations for set types description total number of items in makes copy of return items in but not in the 'tcan be any iterator listtuple or set returns common in both and returns 'trueif nothingis common in and returns 'trueif is subset of returns 'trueis is superset of returns all the items from and twhich are not common in and returns all items from and some of the operations of table are shown belowa [ set(achange 'ato set duplicate entries are removed { [ difference( { set(ts difference( { mutable sets provides some additional methods as shown in table operation on this table will update the set after execution of the commands table methods for mutable set type item description add(itemadd item to clear(remove all items from difference_update(tremvoes all items from swhich are in discard(itemremove item form no error if item not present intersection_update computes the intersetion of and pop(remove an element from remove(itemremove item from if not foundraise keyerror symmetric_difference_update(tsave uncommon entries in and to update(tadd all entries of iterator 'tto some of the operations of table are shown belows { [ add( { symmetric_difference_update(ts (continues on next page builtin types for representing data