Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

How does one go from

> Rule 5. Data dominates. If you've chosen the right data structures and organized things well, the algorithms will almost always be self-evident. Data structures, not algorithms, are central to programming.

to

> Rule 5 is often shortened to "write stupid code that uses smart objects".

"smart objects" left such a bad taste in my mouth, the original rule is so much better albeit lengthier.



I think Rob Pike would agree that "smart objects" is the wrong way to think about it: https://commandcenter.blogspot.com/2012/06/less-is-exponenti...


Seems pretty clear to me, what issue are you having?


Agreed. I find that "smart objects" are much more difficult to make cohesive with one another. Punting your "smart" logic to a higher level is easier to understand, test, and change.


Write code that naturally follows from well-structured objects.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: