The next big topic classes and objects and classes is basically a blueprint of something that's exists
maybe an example we can use like elements elements can be a class and an object will be one individual
made up of this class this blueprint.
Classes can also be like Casals was.
So ever seeing that.
So it connects like with the same attribute attributes.
So an enemy for example could have always have a name and an H.
For example if you have like like a pet.
So it could say pet always has a name and an age and maybe we go on and make like a lot of pets so we
could make like a class or a blueprint.
And if we want to make all pets then we can always reference a class and make a lot of pets or waste
with a name and an age.
And we use this simple example just to get to know like the syntax so how you can make these clauses
and make these objects objects of these classes so it wouldn't get too confusing if we start with like
a programming example so we'd make it really simple and we say you want to make a class or blueprint
say class and then the name of our class and we use.
We start with the uppercase letter.
And our example we called the pet and then we can give these pets different
variables.
So we said all pet all this half has like name.
So we would string and name and we don't initialize it by giving giving for example
giving it's name.
So we just Riot's a lot of variables without even giving it a value.
And then you have an H.
And then if we want to to make one pet so one enema we can make it like this we just say bah.
And then the name of our animal or something maybe Lessie the words and then can say pet and make parentheses
and then close it up.
So this is how we make an object off in class so let's hope we make a class.
And this is how we'd make one instance of this class also called an object.
So this object now and this is how you reference your class.
So you use a class name and to use your brackets.
This is no object no.
And you can give or object.
We can reference our name and age through our object so we can say let's see the name equals and we
say Lessie in parentheses you can say let's see h he quotes three.
And then if you want to get it all you can say Prince
Let's see name and with H would say C H.
And we click run we see three.
So all age and who can of course use it to make make more objects so more pets can say wa maybe cause
for a cat What's that.
So the exact same as on top and then we say discuss name equally that's what's.
And it was curse h equals it's life and then can just print
and then say it was curse name and print it always we click wrong and to say discussant sorry.
If we give Leslie's name Atiya and run it we would see that we really.
Although right it's because we have made different objects out of our class and these objects know can
use like a name and age because we made it an all class and we can set this name and age for our objects
and get these values of here.
So this is our first little example.
It's important to firstly get likes the syntax so so we make our class with our class key word than
the name of our closet and then string and name and age was to use one to have four or four or objects
for pets and then can reference it by saying let's name a c h wiskers name because H.
And before that we have to make an object out of our class and make one instance by referencing a class
tear and then we can use an object to give a name to each.