0
comment
comment
on 4/23/2015 8:25 AM
In my previous post on getting into higher order functions I wrote about how I've been using higher order functions instead of foreach loops. All of the functions defined in that article were immutable, and had no side effects aside from returning data.
In real life though, we're forced to deal with side effects all the time (logging, databases, DateTime.Now, etc).
This separation was by design and is due to an old (in our industry anyway) principal known as Command Query Separation. Command Query Se[...]