Hacker News new | past | comments | ask | show | jobs | submit login
The faster you unlearn OOP, the better for you and your software (2018) (dpc.pw)
18 points by csbartus on June 5, 2021 | hide | past | favorite | 3 comments



OOP is widely spread but not well applied in many cases. After some familiarization with FP, you can develop an appreciation for objects with simpler inheritance of methods and state, and better management of mutability/state changes in the objects. Pure FP is difficult to master, but adopting its principles and limiting mutability within objects and to specific functions helps a lot with OOP.


As much as this is true, OOP is the lingua franca of paradigms. You have to convince others this is true, otherwise any codebase shared by three or more developers will creep back towards it. Then you end up with the FP guy, the OOP guy, and your software project is an incohesive collection of paradigms. The upshot is everyone gets exposure to different ways of thinking, and if they find your approach easier, they'll join you. But what's an easier paradigm is a subjective exercise, we all think differently, of course. To most, there isn't an awareness of anything beyond OOP. Programming is just their 9-to-5 and OOP is a tool for accomplishing the job.


Previous discussion in 2018 [1]

https://news.ycombinator.com/item?id=18526490




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

Search: