import logging


def calc_voltage_extremes(volt):
    """This function calculates the extreme values in the ECG data.

    This functon takes the volt list as input which is the magnitude
    of the ECG data, and finds the extreme values using the max() and
    min() values. The max and min values are returned as a tuple.

    Args:
        volts (list): list of ECG voltage magnitudes

    Returns:
        tuple: (min, max)
    """
    logging.info('Finding max and min ECG values')
    maximum = max(volt)
    minimum = min(volt)
    ans = (minimum, maximum)
    return ans