Skip to main content

One doc tagged with "attributes"

View all tags

Defining Classes: Attributes and Methods

In the last article, we learned that a class is a blueprint and an object is the instance we create from it. We used the init() method to set up the initial data, or attributes, of an object.