A Biscuit producer produces biscuit.
Let's create a class
called Biscuitproducer
.
So far, we have used Carmaker
and Coffeemaker
.
Now, let's use Biscuitproducer
.
The class name does not really matter.
The important thing is that the
class name must start with
a capital letter.
Now let's make a biscuit.
In this case, biscuit1
is
an instance of the class
Biscuitproducer
.
Let's go over class and instance one last time
A class is like a maker,
builder or producer.
An instance is what is
made by using new
.
Here, biscuit1 is an
instance of the class
Biscuitproducer.