Implementing `sequenceA` I implemented sequenceA:

sequenceA :: Applicative f =&gt; [f a] -&gt; f [a]
sequenceA []     = pure []
sequenceA (x:xs) = (++) &lt;$&gt; (fmap (\y -&gt; [y]) x) &lt;*&gt; sequenceA xs


I don't like the fact that I'm making a new list, and then concatenating the result via ++.

However, I'm not sure how to make use of cons, i.e. :, in this function.

Please critique it.
The trick is to lift (:) into the applicative functor using pure thus getting an expression of type f (a -&gt; [a] -&gt; [a]) which you can then apply using (&lt;*&gt;). This gives you: sequenceA (x:xs) = pure (:) &lt;*&gt; x &lt;*&gt; sequenceA xs.

Now, the pattern pure ... &lt;*&gt; is equivalent to ... &lt;$&gt; so we can rewrite the previous equation to the shorter solution:

sequenceA (x:xs) = (:) &lt;$&gt; x &lt;*&gt; sequenceA xs


This pattern can be generalized to other datatypes: see the traversable typeclass. sequenceA can always be implemented for datatypes* by using pure to lift constructors and (&lt;*&gt;) to apply arguments (or induction hypotheses).

* strictly positive ones, at least