r/PythonLearning • u/TappuXT • 29d ago
I want to learn (class) object oriented programming in python .I saw 1-2 videos but i have't understand .May anyone suggest me from where I should learn this and complete python.
Suggest the best videos to learn python .
2
1
u/The_ONE_393 26d ago
Videos rarely make classes click, since OOP tends to settle after writing a few small classes and breaking them on purpose. Bootdev could help there with interactive exercises on classes and objects, where each concept gets used immediately instead of just watched.
1
u/stepback269 28d ago
Me too.
I had / still have trouble understanding "class" and OOP in general
Many tutorials settle on the word, "blueprint" or "template" for explaining what the class def statement does.
I didn't find those metaphors very helpful. Instead "cookie cutter" did better for my hard-to-please brain
For more on this topic, check out my page at (this blogspot link)
1
u/ee_control_z 28d ago edited 28d ago
Better:
Learning Python, 6 Ed, Mark Lutz
I strongly recommend this book. It covers just about everything you need to know about OOP. Very well written so it is easy to understand.
1
u/Sea-Ad7805 28d ago
This visualizer can help you learn Object Oriented Programming (OOP) easier/faster.
The basics of OOP involve:
Use a
classto group values that belong together (name, weight, height).Create objects (persons) of the class.
Use the functions in the class, that use
self, to do things with these objects (print, get_bmi).
Happy learning.
1
u/hungry_buddy_here 28d ago
have you tried learning from yt, many people ignores it , but tbh that is a really good source for learning anything in the world even
1
u/HyperDanon 28d ago
Classes in python tend to be mixes of objects and structures. Proper oo objects aren't structures, they aren't supposed to "hold data", they're not containers. Objects should encapsulate behaviour, and optionally hold private state, but not as a a "data holder" but as a means to facilitate the behaviour.
Be careful of people recommending that oo is "modeling the real word", that's nonesense.
Please, paste an example program you have created. It could be easier to just take the code, and recognize objects in it.
1
u/masterofaiml 28d ago
Keep practicing while you learn, that’s how you learn any programming language, just watching videos or reading doesn’t help.
Try www.pythonmastery.io, it has everything you need to learn and practice python. Best part is, it’s all free and if you like it consider sharing it.
Happy learning!
1
1
u/Boukef23 27d ago
When i stuck like this after watching more than two videos I try to pause everything and think with my self what actually i dont understand in detail
Not like i dont understand oop ... to abstract and general
Instead
I dont know when and how to use heritage in java ... deep and detailed
And ask llm with more practics instead whatch videos this will save u a lot of time
1
u/TalesGameStudio 27d ago
Thete will be a
class Person
who can tell you, what OOP is. You just need a
person = Person()
to really do it.
1
u/TimBrownDev 28d ago
After 10 years tutoring, I'm building a roadmap of hand-picked practice problems to help teach python from zero to mastery. There are sections for OOP you can learn & practice.
3
u/Salty_Dig8574 28d ago
This short video was a game changer for me. Pun intended.