I don't understand class objects and how to use them


#1

Currently behind on the Programming with Python course because I do not understand anything about class objects. I don’t want to run out of time, and I’ve spent about a week trying to search up how to use them. (Currently doing Basta Fazoolin project, stuck on step 3.)


#2

is this part of pro-intensive course?

There is so much information about python classes (and classes in general), surely you must be able to find some of these guides/wikis/explanations?

Writing an very extensive answer about classes in general cost a lot of time, and its not time well spend given so much information already exist


#3

Yes, this is part of the pro-intensive course. And no, I haven’t found anything really useful, like how to make a dictionary linked to an object.


#4

its generally advised to use the slack channels for this (you should have gotten an invite), given there are very few people with intensive access on the forum

in python, objects are class instances.

you can have a dictionary as instance or class variable:

class Example:
   class_dictionary = {}
   def __init__(self):
      self.instance_dictionary = {}

e = Example()
print(e.class_dictionary)
print(e.instance_dictionary)

otherwise i have no idea what you mean


#5

i tried to avoid having to download slack because i won’t be needing it after the course, but i think i have to at this point. also what i meant was that i don’t know how to link a class object to a time and a parameter


#6

slack also has a web version, which just runs in the browser. So that is no excuse

if you want me to explain this, please phrase a better question. Don’t forgot that i have never seen the course, so your question would need to include code samples and instructions


#7

wait slack has a web version?
i was not aware, thanks for telling me
i’ll ask there


#8

yes, just go to slack.com


#9

how do i get an invite


#10

you should have gotten an invite when you enrolled in pro-intensive, i suppose by email, but like i said, never did pro-intensive, so don’t know.


#11

alright i looked in my email and i got it, thanks for the help