imppkg.harmonic_mean module

imppkg.harmonic_mean.harmonic_mean()

Calculates the harmonic mean of a list of floating-point numbers. https://en.wikipedia.org/wiki/Harmonic_mean

Parameters: numbers (List[Union[float, int]]): A list of floating-point numbers to calculate the harmonic mean of.

Restrictions: numbers list should contain only numeric values(int or float) numbers list should contain only positive numbers (greater than zero) numbers list should not be empty

Returns: float: The harmonic mean of the given numbers.