Hoogle Search

Within LTS Haskell 24.4 (ghc-9.10.2)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. sum :: (Foldable t, Num a) => t a -> a

    incipit-base Incipit.Foldable

    The sum function computes the sum of the numbers of a structure.

    Examples

    Basic usage:
    >>> sum []
    0
    
    >>> sum [42]
    42
    
    >>> sum [1..10]
    55
    
    >>> sum [4.1, 2.0, 1.7]
    7.8
    
    >>> sum [1..]
    * Hangs forever *
    

  2. sum :: (Generator c, Num (Elem c)) => c -> Elem c

    reducers Data.Generator.Combinators

    Efficiently sum over the members of any Generator

    reduceWith getSum
    

  3. sum :: forall (m :: Type -> Type) a . (Monad m, Num a) => Fold m a a

    streamly-core Streamly.Data.Fold

    Determine the sum of all elements of a stream of numbers. Returns additive identity (0) when the stream is empty. Note that this is not numerically stable for floating point numbers.

    >>> sum = Fold.cumulative Fold.windowSum
    
    Same as following but numerically stable:
    >>> sum = Fold.foldl' (+) 0
    
    >>> sum = fmap Data.Monoid.getSum $ Fold.foldMap Data.Monoid.Sum
    

  4. sum :: forall (m :: Type -> Type) a . (Monad m, Num a) => Fold m a a

    streamly-core Streamly.Internal.Data.Fold

    Determine the sum of all elements of a stream of numbers. Returns additive identity (0) when the stream is empty. Note that this is not numerically stable for floating point numbers.

    >>> sum = Fold.cumulative Fold.windowSum
    
    Same as following but numerically stable:
    >>> sum = Fold.foldl' (+) 0
    
    >>> sum = fmap Data.Monoid.getSum $ Fold.foldMap Data.Monoid.Sum
    

  5. sum :: C a => [a] -> a

    battleship-combinatorics Combinatorics.Battleship.Count.Counter

    No documentation available.

  6. sum :: (Foldable t, Num a) => t a -> a

    calligraphy Calligraphy.Prelude

    The sum function computes the sum of the numbers of a structure.

    Examples

    Basic usage:
    >>> sum []
    0
    
    >>> sum [42]
    42
    
    >>> sum [1..10]
    55
    
    >>> sum [4.1, 2.0, 1.7]
    7.8
    
    >>> sum [1..]
    * Hangs forever *
    

  7. sum :: (Foldable t, Num a) => t a -> a

    clash-prelude Clash.HaskellPrelude

    The sum function computes the sum of the numbers of a structure.

    Examples

    Basic usage:
    >>> sum []
    0
    
    >>> sum [42]
    42
    
    >>> sum [1..10]
    55
    
    >>> sum [4.1, 2.0, 1.7]
    7.8
    
    >>> sum [1..]
    * Hangs forever *
    

  8. sum :: (C sh, Floating a) => Vector sh a -> a

    comfort-blas Numeric.BLAS.Vector

    forVector number_ $ \xs -> Vector.sum xs == List.sum (Vector.toList xs)
    

  9. sum :: (C sh, Floating a) => T shA sh a -> a

    comfort-blas Numeric.BLAS.Vector.Slice

    forSliced number_ $ \xs -> VectorSlice.sum xs == List.sum (listFromSlice xs)
    

  10. sum :: (Typed a, Num a, Eq a) => Int -> Stream a -> Stream a

    copilot-libraries Copilot.Library.Statistics

    Summation.

Page 16 of many | Previous | Next