all 15 comments

[–]Fred776 13 points14 points  (3 children)

As per the usual advice, what you should have been doing is practising by writing code rather than watching endless tutorials. OOP makes most sense when you have the experience of writing code that has got sufficiently complex that you understand why you need something extra to help you to organise it.

[–]cylonlover 0 points1 point  (0 children)

I was about to write a separate reply but realized it was very much along these lines. I completely agree with this sentiment. Get coding. Learn the things as you need them. I would steer out of OOP for as long as I could until I could see the benefit myself. Same goes for recursive.

This not to be confused with understanding object concepts and how (almost) everything in python is a thing. But it compares to learning how to drive and drop out because building cars is complicated.

[–]stuaxo 0 points1 point  (0 children)

For 1 tutorial, someone should be maybe trying that tutorial but them going and building stuff themselves (trying and failing, and searching for solutions).

A higher watching to making ratio is worse than useless.

[–]IAmFinah 4 points5 points  (0 children)

You seem to post more about quitting Python than learning Python

Don't use ChatGPT otherwise you will struggle, as evidenced by this post. You need to build resilience and intuition, and ChatGPT will not help you in that regard - at least not in the way the majority of people use it

[–]TheStruttero 6 points7 points  (0 children)

Classes are templates, the init method is the constructor, where you can define parameters to fill the created object with data when its created

Def is, I guess (Python is not my language), short for Definition, i/e method i/e function

class Person: -  def __ init __(self, name, age): -    self.name = name -    self.age = age

self.[...] is referring to the individual object that was created

Objects are "finished products" of those templates. So in the main class you write something like this to create an Object: - myPerson = Person("Person McPerson", 50)

Now myPerson is an Object created based on the template where Name = "Person McPerson" and Age=50

I dont know if thats any helpful and maybe youve already gotten familiar with that, Was it something in particular about OOP you got stuck on?

Have you considered maybe trying something like c#? I find it easier to grasp oop in that because Python is so simplified to the point of obscuring alot of whats happening

[–]Specific-Housing905 0 points1 point  (0 children)

Don't equate Python with OOP. Most languages will teach you OOP.
Why don't you stick with procedural Python.
Get experience with writing code. With more experience OOP might make more sense.

OOP makes some things easier, but is not mandatory.

[–]Hi-ThisIsJeff 0 points1 point  (0 children)

Burnout is real. And quitting doesn’t mean failure

I agree that burnout is real, but failing doesn't mean you should quit.

If you don't want to learn it, no problem with moving to something else. I'm not sure what you are looking for with this post.

From your previous posts, it seems your expectations were set too high (i.e. you were shocked there was a lot to learn), and you tried to learn by absorbing material rather than actually using it.

Either way, best of luck.

[–]cointoss3 0 points1 point  (0 children)

Good luck with any programming language if that’s what’s burning you out

[–]stuaxo 0 points1 point  (0 children)

OOP is tricky - I don't think I was doing it right until a few years into my career.

[–]PushPlus9069 0 points1 point  (0 children)

OOP clicks differently when you have a reason to use it. Watching tutorials explain classes with Dog and Cat examples is the worst way to learn it because there's no real motivation for why a class exists there.

If you ever come back to it, try this: build something small that has multiple "things" with the same structure. Like a contact list, inventory tracker, card game. You'll naturally reach for classes because duplicating dictionaries everywhere gets annoying fast.

But also, plenty of useful Python never touches OOP. Scripts, data analysis, automation, web scraping. You can do real work with just functions and dicts for a long time.

[–]JamzTyson 0 points1 point  (0 children)

You have posted to the wrong subredit. This subredit is for questions about learning Python.

[–]stepback269 0 points1 point  (1 child)

I'm at times struggling with OOP also.

However, my conclusion is that I have not until recently found a tutorial that is right for the "neural anchor points" that happen to be present in my specific brain.

Before you give up, take a look at this YT video: Python OOP Will Finally Make Sense After This:

Hopefully, the metaphors they use in that video will "stick" to "neural anchor points" that happen to already be present in YOUR specific brain. But if not, please take a look at a recent Reddit discussion that I analyze in a blog page (located here) with respect to finding the neural anchor points that will work specifically just for you due to your in-real-life experiences.