[Haskell-beginners] fmap fmap

Federico Brubacher fbrubacher at gmail.com
Sun Aug 9 12:39:08 EDT 2009


fmap . fmap is close to applicative ?
is it possible to do applicative instead of combining 2 fmaps ?

Thanks

On Wed, Aug 5, 2009 at 12:29 AM, Tony Morris <tonymorris at gmail.com> wrote:

> Michael P Mossey wrote:
> > How does one write
> >
> > fmap (fmap (*2)) xs
> >
> > without parenthesis? (Using . and $ instead.)
> >
> > I don't really understand . and $ well enough I guess. I tried a bunch
> > of stuff but nothing worked.
> >
> > -Mike
> > _______________________________________________
> > Beginners mailing list
> > Beginners at haskell.org
> > http://www.haskell.org/mailman/listinfo/beginners
> >
> fmap . fmap $ (*2)
>
> or perhaps:
>
> (fmap . fmap) (*2)
>
> --
> Tony Morris
> http://tmorris.net/
>
>
> _______________________________________________
> Beginners mailing list
> Beginners at haskell.org
> http://www.haskell.org/mailman/listinfo/beginners
>



-- 
Federico Brubacher
www.fbrubacher.com

Colonial Duty Free Shop
www.colonial.com.uy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/beginners/attachments/20090809/38c455d7/attachment.html


More information about the Beginners mailing list