+ 2

what is the difference between a function and a class?

when would you use one and or not the other? I'm confused.

16th Oct 2017, 10:41 AM
Auriel Joyner
Auriel Joyner - avatar
1 Answer
+ 2
these two are totally different things, classes are like new data types you define yourself, they have instance variables and functions that are called methods, so you see a function can be part of a class, but you can only call these functions on objects/instances of the class
16th Oct 2017, 11:05 AM
‎ɐısıօՏɐ
‎ɐısıօՏɐ - avatar