Python Forum
Understanding Python super() for classes
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Understanding Python super() for classes
#1
Good day, Dear Pythonistas

Could you, please, explain in a simple way why super() is used for classes sometimes. I saw many examples dealing with single inheritance and multiple inheritances, it is explained that this approach could make the whole structure more manageable, but what are the conceptual framework and practical applications? (Is it typical for a large project or what?)
Reply
#2
Check Python’s super() considered super! by Raymond Hettinger and on youtube - https://youtu.be/EiOglTERPEo
and also https://realpython.com/python-super/
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs

Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  updating pip, python - understanding terminal and pycharm. endlessnameless 0 1,140 Jun-24-2024, 05:48 AM
Last Post: endlessnameless
  Problems with super() Hoespilaar 3 1,760 Jun-11-2024, 02:15 AM
Last Post: kanetracy
  Python Classes rob101 4 1,504 Feb-05-2024, 06:51 PM
Last Post: rob101
  super() in class akbarza 1 2,622 Dec-19-2023, 12:55 PM
Last Post: menator01
  Understanding venv; How do I ensure my python script uses the environment every time? Calab 1 4,730 May-10-2023, 02:13 PM
Last Post: Calab
  New to python/coding Need help on Understanding why this code isn't working. Thanks! mat3372 8 3,495 May-09-2023, 08:47 AM
Last Post: buran
  Understanding Python classes PythonNewbee 3 2,145 Nov-10-2022, 11:07 PM
Last Post: deanhystad
Sad Python classes PythonNewbee 4 2,102 Nov-09-2022, 01:19 PM
Last Post: deanhystad
  super multiple parallel classes catlessness 2 2,036 Jun-07-2022, 02:35 PM
Last Post: deanhystad
  I need help understanding a program structure using classes CompleteNewb 21 9,571 Feb-24-2022, 07:15 PM
Last Post: deanhystad

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020