elm-community / list-extra

Convenience functions for working with List.
http://package.elm-lang.org/packages/elm-community/list-extra/latest
MIT License
135 stars 59 forks source link

andMap's example is incorrect #29

Closed montanonic closed 7 years ago

montanonic commented 7 years ago

The example uses the following code:

((\a b c -> a + b * c)
    |> map [1,2,3]
    |> andMap [4,5,6]
    |> andMap [2,1,1]
) == [9,7,9]

But it should be:

((\a b c -> a + b * c)
    |> flip map [1,2,3] -- change here
    |> andMap [4,5,6]
    |> andMap [2,1,1]
) == [9,7,9]
prikhi commented 7 years ago

Thanks for the report :+1: