What is a behavior in objects/constructor world?

I’m at the oop section of Js course, and in further challenges I keep reading about properties and behaviors of an object, I understand what a property is but I can’t seem to imagine what a behavior is like or what it is?
can somebody elaborate on what that is? with an example would be great.
thank you

Think of a property as a characteristic of what you are modelling. Behaviors would be methods (functions) to perform some kind of task.

If you are creating a Dog, then a property of the dog could be name. A behavior of the do could be bark.

1 Like