3 ms·
Ousterhout's book "Philosophy of Software Design" discusses that a developer's goal is to reduce complexity. I also personally maintain this idea at work. So i
by adamredwoods 2y ago
Ousterhout's book "Philosophy of Software Design" discusses that a developer's goal is to reduce complexity. I also personally maintain this idea at work.
So if the OOP class is confusing, it has not met its goal. One could also argue that functions "do one thing" to reduce complexity, and if that one thing is to return a string, your function has succeeded.
Ousterhout also writes about "deep" functions versus "shallow" functions. "Deep" referring to a function that does a lot, without the caller doing a complex series of functions to get the end result. So subjectively, a single function with a lot of logic would be "more correct" than a class with many shallow methods.
- timw4mail 2y agoThat is my favorite software book. Deep implementations, but shallow interfaces is a good rule of thumb.