Skip to content

Mean should return undefined when array is empty #12

@Odonno

Description

@Odonno

Indead, I suppose that when mean is used with an empty array, it divides by 0 and so it returns NaN. I think it would be more appropriate to return undefined when we cannot execute the calculation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions