converselythe intersection method accepts second set and returns new set that contains only those elements that are in both sets it is like logical and operationand can also be referenced using the operator finallythe symmetric_difference method tells us what' leftit is the set of objects that are in one set or the otherbut not both the following example illustrates these methods by comparing some artists from my song library to those in my sister'smy_artists {"sarah brightman""guns nroses""opeth""vixy and tony"auburns_artists {"nickelback""guns nroses""savage garden"print("all{}format(my_artists union(auburns_artists))print("both{}format(auburns_artists intersection(my_artists))print("either but not both{}formatmy_artists symmetric_difference(auburns_artists))if we run this codewe see that these three methods do what the print statements suggest they will doall{'sarah brightman'"guns nroses"'vixy and tony''savage garden''opeth''nickelback'both{"guns nroses"either but not both{'savage garden''opeth''nickelback''sarah brightman''vixy and tony'these methods all return the same resultregardless of which set calls the other we can say my_artists union(auburns_artistsor auburns_artists union(my_artistsand get the same result there are also methods that return different results depending on who is the caller and who is the argument these methods include issubset and issupersetwhich are the inverse of each other both return bool the issubset method returns trueif all of the items in the calling set are also in the set passed as an argument the issuperset method returns true if all of the items in the argument are also in the calling set thus issubset(tand issuperset(sare identical they will both return true if contains all the elements in