functional-programming-jargon icon indicating copy to clipboard operation
functional-programming-jargon copied to clipboard

Is array concatenation a monoid?

Open thanhnguyen2187 opened this issue 1 year ago • 0 comments

I'm not so sure about the monoid section, where it's stated that:

Array concatenation also forms a monoid

With the example:

[1, 2].concat([3, 4])

I don't feel like array concatenation satisfies "associativity" at all, since a.concat(b) clearly differs from b.concat(a). Can someone explain this for me?

thanhnguyen2187 avatar Jun 12 '23 12:06 thanhnguyen2187