News for hackers. Stuff that matters.
Re:Python is now the most popular introductory language at t... by codygman on Monday July 07, 2014 @07:14PM (#8002156)
Right, I think that once the concept is taught of what mapM does/means it will be easier to keep applying than something like a foreach loop.

The reason being that "<mapfn> <somefn> <list>" is more declarative, whereas the foreach loop is ambiguous. Something we often take for granted is how hard it was at first to come up with what exactly we need to do or mutate inside that loop to build the right result.

If nothing else, there is interesting discussion to be had ;)

There are no comments on this comment yet.