Skip to content

Commit b424064

Browse files
Provide a simple graph reduction of examples in Array's Bind explanation
1 parent d939da5 commit b424064

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/Control/Bind.purs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,12 @@ instance bindFn :: Bind ((->) r) where
7272
-- | ["c", "d"] >>= \eachElementInArray2
7373
-- | pure (eachElementInArray1 <> eachElementInArray2)
7474
-- |
75-
-- | foo == [ ("a" <> "c"), ("a" <> "d"), ("b" <> "c"), ("b" <> "d") == [ "ac", "ad", "bc", "bd"]
75+
-- | -- In other words...
76+
-- | foo
77+
-- | -- ... is the same as...
78+
-- | [ ("a" <> "c"), ("a" <> "d"), ("b" <> "c"), ("b" <> "d") ]
79+
-- | -- which simplifies to...
80+
-- | [ "ac", "ad", "bc", "bd"]
7681
-- | ```
7782
instance bindArray :: Bind Array where
7883
bind = arrayBind

0 commit comments

Comments
 (0)