• Computes the sum of the values in array.

    Parameters

    • collection: undefined | null | List<any>

    Returns number

    Returns the sum.

    _.sum([4, 2, 8, 6]);
    // => 20