13 Nov 18:11
Re: Could someone teach me why we use Data.Monoid?
Magicloud Magiclouds <magicloud.magiclouds <at> gmail.com>
2009-11-13 17:11:27 GMT
2009-11-13 17:11:27 GMT
That is OK. Since understand the basic concept of monoid (I mean the thing in actual math), the idea here is totally not hard for me. But the sample here does not show why (or how) we use it in programming, right? On Sat, Nov 14, 2009 at 12:48 AM, Stephen Tetley <stephen.tetley <at> gmail.com> wrote: > 2009/11/13 Rafael Gustavo da Cunha Pereira Pinto <RafaelGCPP.Linux <at> gmail.com>: >> >> Monoid is the category of all types that have a empty value and an append >> operation. >> > > Or more generally a neutral element and an associative operation: > > The multiplication monoid (1,*) > > 9*1*1*1 = 9 > > 1 is neutral but you might be hard pressed to consider it _empty_. > > > Best wishes > > Stephen > _______________________________________________ > Haskell-Cafe mailing list > Haskell-Cafe <at> haskell.org > http://www.haskell.org/mailman/listinfo/haskell-cafe > -- -- 竹密岂妨流水过 山高哪阻野云飞
RSS Feed