Question: what is the difference between function & class?
Answer: The most obvious difference from a class and an object is that classes serve only one purpose, they are the template from which objects inherit properties and functionality. ... An object is a collection of functions and data. A function is a collection of commands and data.