Question: what is the difference between attribute and method in python?
Answer: Methods are functions that belong to your object. There are additional hidden attributes present on all classes, but this is what your exercise is likely talking about. A method is a function defined in the class. An attribute is an instance variable defined in the class.