Alexander Bandukwala

99%
Flag icon
In the second chunk of code, each step returns an object that implements the next function we call: the object returned by content_of must implement find_matching_lines, and so on. This means that the object returned by content_of is coupled to our code. Imagine the requirement changed, and we have to ignore lines starting with a # character. In the transformation style, that would be easy:
The Pragmatic Programmer: Your Journey to Mastery, 20th Anniversary Edition
Rate this book
Clear rating
Open Preview