'Returns True if other is contained in self, where other
belongs to extended real numbers, False if not contained,
otherwise TypeError is raised.
Examples
>>> from sympy import AccumBounds, oo
>>> 1 in AccumBounds(-1, 3)
True
-oo and oo go together as limits (in AccumulationBounds).
>>> -oo in AccumBounds(1, oo)
True
>>> oo in AccumBounds(-oo, 0)
True'

def __contains__(self, other):

    other = _sympify(other)
    if (not (other.is_Symbol or other.is_number)):
        raise TypeError('Input    of    type    real    symbol    or    Number    expected')
    if ((other is S.Infinity) or (other is S.NegativeInfinity)):
        if ((self.min is S.NegativeInfinity) or (self.max is S.Infinity)):
            return True
        return False
    return And(((self.min <= other) and (self.max >= other)))
