:: (Monad m) => m a -> (a -> m b) -> m b -package:base

Sequentially compose two actions, passing any value produced by the first as an argument to the second. 'as >>= bs' can be understood as the do expression
do a <- as
bs a
Sequentially compose two actions, passing any value produced by the first as an argument to the second.
Sequentially compose two actions, passing any value produced by the first as an argument to the second. 'as >>= bs' can be understood as the do expression
do a <- as
bs a
An alternative name for this function is 'bind', but some people may refer to it as 'flatMap', which results from it being equivalent to
\x f -> join (fmap f x) :: Monad m => m a -> (a -> m b) -> m b
which can be seen as mapping a value with Monad m => m a -> m (m b) and then 'flattening' m (m b) to m b using join.
Function name for >>=, as fmap is to <$>.
(≫=) = (>>=) (U+226B, MUCH GREATER-THAN) + (U+3D, EQUALS SIGN)
Generalized version of for_ :: Applicative m => [a] -> (a -> m ()) -> m ()
Same as >>=, but with the arguments interchanged.
For chaining monadic operations in forward applications using (&) Named version of =<<.
>>> Just [ 1 :: Int ] & chainedTo (viaNonEmpty head)
Just 1

>>> Nothing & chainedTo (viaNonEmpty head)
Nothing
Same as >>=, but with the arguments interchanged.
as >>= f == f =<< as