def __init__(self, appliances=None):
self.appliances = [] if appliances is None else appliances
if not isinstance(self.appliances, list):
raise TypeError()
def __getitem__(self, key):
Get a single appliance.
Three formats for `key` are accepted:
After Change
appliances : set of Appliances
def __init__(self, appliances=None):
self.appliances = set() if appliances is None else set(appliances)
def union(self, other):
Returns