Python Forum
Using classes? Can I just use classes to structure code?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Using classes? Can I just use classes to structure code?
#5
Think of a class as a collection.  Like a dictionary, that can have actions instead of just data.  For your example, you'd have probably an Artist, a Record/Album, and maybe a Track class, if you had some tracks that were on multiple albums (collections, or collaborations).
Reply


Messages In This Thread
RE: Using classes? Can I just use classes to structure code? - by nilamo - Nov-01-2017, 02:35 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Python Classes rob101 4 527 Feb-05-2024, 06:51 PM
Last Post: rob101
  How do I classify colored images into 3 classes max22 0 672 Dec-04-2023, 10:33 PM
Last Post: max22
Question [solved] Classes, assign an attributes to a class not to instances.. SpongeB0B 4 930 May-20-2023, 04:08 PM
Last Post: SpongeB0B
  Organizing several similar classes with overlapping variables 6hearts 7 1,376 May-07-2023, 02:00 PM
Last Post: 6hearts
  Q on classes ebolisa 4 866 Mar-06-2023, 04:17 PM
Last Post: deanhystad
  which design / pattern when building classes and subclasses Phaze90 2 1,123 Nov-19-2022, 08:42 AM
Last Post: Gribouillis
  Understanding Python classes PythonNewbee 3 1,184 Nov-10-2022, 11:07 PM
Last Post: deanhystad
Sad Python classes PythonNewbee 4 1,046 Nov-09-2022, 01:19 PM
Last Post: deanhystad
  super multiple parallel classes catlessness 2 1,327 Jun-07-2022, 02:35 PM
Last Post: deanhystad
  Adding Decimals to classes with OOP + rounding to significant digits (ATM demo) Drone4four 7 2,292 May-04-2022, 06:15 AM
Last Post: Drone4four

Forum Jump:

User Panel Messages

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