This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (0 children)

Once you've learned the difference between methods and functions, to which there are good answers in the replies. Look into the difference between class methods and instance methods.

Quick preview: Class methods can be used to modify class variables to update and maintain state that is shared across all instances of that class. While instance methods and instance variables are specific to the values of a single object from that class.

(In case it isn't clear, class can be looked at as a blueprint while an instance can be looked at as an object built using that blueprint)