code: def bounding_box(locations):
      
      x_values = list(map(itemgetter(0), locations))
      x_min, x_max = min(x_values), max(x_values)
      y_values = list(map(itemgetter(1), locations))
      y_min, y_max = min(y_values), max(y_values)
      return Rect(x_min, y_min, x_max - x_min, y_max - y_min)
docs: Computes the bounding box of an iterable of (x, y) coordinates.
  
      Args:
          locations: iterable of (x, y) tuples.
  
      Returns:
          `Rect`: Coordinates of the bounding box.