"""
This module provides various mathematical functions.
"""

def is_in_closed_interval(n, left, right):
    """
    Check if a number is within the closed interval
    between left and right.
    """
    return left <= n <= right