merge method

Interval merge(
  1. Interval other
)

Outermost union of this interval with other.

Implementation

Interval merge(Interval other) {
  return Interval(math.min(min, other.min), math.max(max, other.max));
}