|
|
|
|
|
by drekipus
1016 days ago
|
|
Depends on the example.
Going off the blurb: > it’s a way of breaking down a complex function into smaller, simpler functions that can be composed together to achieve the same result. And you could almost see it as analogous to the "fluent" pattern like: GetObject()
.add(3)
.applyGradient()
.giveFish()
Etc.
On the side: I really hate the "make it less complex" PR comments because it's not complex, it's just hard to read, and that's usually because the reader doesn't know about them.I have one guy in our company who wants to unravel any list comprehension or map/generators functions (python) because he doesn't know anything except "for X in Y" |
|
At the time I had a coworker who was militant about "simple code" and anti "complexity". I used to argue that the code they preferred was more of a pain in the butt due to avoiding anything beyond the most basic of constructs. They saw that this was a talk, suggested our team watch it, and then became upset because it turned out they hadn't actually watched it and assumed based on the title that it'd back up their viewpoints.
Lowest common denominator coding isn't the same thing as avoiding complexity.