Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
It depends on the situation. There are many cases in which a functional language (eg haskell) is better.
-
willol13898yParadigms often aren't incompatible y'know! Just avoid to object orient for the sake of object orienting, you'll be good.
-
SnuKies3748yI like to think like this about OOP: imagine a house, with no inner walls. So it's all a big room. You can put there a bed, an oven, a toilet... You can have everything there, but when you'll feel a bad smell, you won't know if it was the toilet or the stove. Is it practical? Not really...
Now imagine you have walls. Now the kitchen is the kitchen, toilet toilet and so on. You don't have to worry about privacy when some people are over. And if something bad smells, you'll know where it came from.
I like to think same about OOP. -
Redders9578y@LicensedCrime no, you're assuming the choice is between OOP and spaghetti, there are other choices, lime functional programming!
-
Kanimaru7768yIt depends on the project. For a game I would prefer ECS over OOP just cause of the flexibility.
-
Paradigm5628y@SnuKies That is probably the best argument I've heard in layman's terms for using OOP over functional programming.
-
When writing my games I go with a data oriented approach. Sure, not the friendliest looking code but its fast and really you should be documenting anyway.
Not OOP != Not organized -
Redders9578y@DLMousey yeah, I guess if oop is all you know, other ways of thinking would be hard to follow
-
sljux7218yOOP is just another tool, it can be used right, and you can saw your leg off. This tool comes with a User Guide called Design Patterns and Principles, which is the main reason a bunch of devs saw their metaphorical limbs off.
-
Probably isn't the "best", but is definitely the most commonly used simply because a lot of projects happen to be easily described by an OOP-based pattern.
Related Rants
Dont lynch me or anything but...
What if OOP _isn't_ the best programming paradigm?
undefined
oop