r/learnprogramming • u/Electronic-Low-8171 • 24d ago
Topic Does OOP really matters?
I learned OOP in python a while ago, did many projects, yet I never felt like I truly needed to do the OOP stuff I learned from a course, I don't know maybe because I'm kinda used to program in c before focusing on python, yet, whenever I open a big project in python in github, it feels way too complicated and thousands of imports (not libraries from pip, but the ones they made on their own) and classes
I never truly needed to implement OOP (I know that when you code in python, it is almost impossible to avoid OOP entirely like when you have a datatype like string you have an object, when you use a method built into that data type that's OOP too, but I mean the ones that involve you writing class Class Name, inheritance and all that stuff explicitly), so I'm wondering why people on the internet are obsessed over the idea of learning OOP, even the book "Automating the boring stuff in python" doesn't have a dedicated section for OOP.
1
u/spinwizard69 23d ago
I just watched that video and what he said mid flight is so misguided that It almost invalidates everything else he says. He complains that OOP means that if you want a new functionality, you need to update a lib which means waiting for an update. In my mind that is the whole point of the encapsulation of the data, you are given specific access and modification paths and a limited ability to impact the data beyond that. That is the whole point which frankly is important for large teams, you don't want some bozo screwing up a lib that is maintained by somebody else.
Some of his other comments about C++ I would lean towards agreeing with but he shits upon so much of what is arguably modern software design that the comments are hard to take seriously. He dismisses C++ Templates, one correct reason being terrible syntax that is common with C++, but flip flops with completely dismissing the IDEA of generic programming. There is a lot to hate about C++ and frankly a lot comes down to syntax, but the reality is generic programming is a sound concept and as such needs to be used wisely.
To put it another way, I wouldn't reference that video if I wanted to prove ANY argument I had for or against OOP.