OK, so now we are back to A.J. and our quote from the Variables Lecture, we have a list of data that
we will use and create variables based on that.
All right.
Let's jump right into that.
So let's start with bitts.
Before that, the laid line we created in the last lecture, this one.
So the first one was the number of seats, which was five, I guess.
So as I showed you in the variables lesson data type, variable name equals value and a semicolon at
the end of the line.
So Boyte.
Number of seats and as you can see, I'm using Camil case here equals five and a semicolon.
So that's it.
It is easy.
Let's define other variables to a tip.
It is really easy to duplicate lines with Control Plasty or Almac Command plus DB, but you can use
copy paste here to.
OK, three bite type attributes were on the side, so control plasty and hand number of those.
It was three.
And number of vehicle owners.
Which was one.
And emmissions taka.
Changing the name mission sticker.
It was for now, let's move on to shorts, only thing is changing here is the day to type.
So first, short power.
Equals three hundred and sixty two and a semicolon, you can use power or power in kilowatts as variable
name, it is really up to you.
The next one is horsepower.
So doubling this line, horse power with uppercase.
And it was four hundred and ninety two then CO2 emission.
In case of CO2, we can use numbers in the variable name, but you can also use letters so you can type
in two.
It's really up to you again.
Both correct.
So doubling this line and here.
CO2 emission equals and it was 333 and last shorthair cubic capacity, so doubling this line again,
deleting this part.
And it was six thousand four hundred seventeen, OK, in the end, we had price and mileage, so here
and price equals twenty nine thousand nine hundred and ninety nine and a semicolon and doubling the
Seline mileage.
And it was for thirteen thousand nine hundred and ninety nine.
That's it here, we're going to add an extra thing, we are going to create a long for registration
number when you start creating long and the beginning is the same, so long registration
number equals a lot of numbers and a semicolon.
So when you're finished with adding some extra numbers and a semicolon, you realize that something
is not OK.
The problem here is that when you create a long you have to add an hour to the end, uppercase or lowercase,
you can use both.
But I recommend you to use uppercase because lowercase l looks very similar to one.
So adding an hour here will remove this threat underline.
That's it.
So the reason why we have to add Al, to the long numbers will be explained later.
For now, I can say that the full data type for whole numbers as end and for floating point numbers
is double in case of long and float.
We have to tell Jova the exact data type of the number.
It's a bit simplified, but don't worry, I will make it all clear so we are almost done.
Let's define floating point numbers so we have three float values combined, urban and exurban fuel
consumption.
So here float fuel consumption combined equals and it was fifteen point five.
And we have to add an F here and a Samwick on the next one as urban.
So removing this combined and replacing with urban and changing the number to twenty one point four
and one more the extra urban.
So adding extra hair and changing this wire to thirteen point six.
So as you can see, I changed the order of the words, the reason is that this way it is easier to read
and see that the variables are connected to each other.
OK, I know we didn't have double on the website, but let's define one, we are still the precise average
fuel consumption.
So here double fuel consumption, size average.
Equals and 15 points and a lot of random numbers.
And a semicolon, we can manipulate the number and define how many times we would like to multiply or
divide it with ten to do that, let's put an E and a number to the end of the number.
So adding E one and dividing the number with ten.
So this way, one point five will give us the same number and doing it the opposite way.
Just adding a negative here.
We still have the same number.
OK, now leave it as it is just to prove that this works properly.
OK, just a side note.
It works only with double and float.
Now, let's move on to more variables left.
One is Boolean is damaged.
So here.
Bullion is damaged, equals two and a CHA for energy efficiency.
Category.
Equals simple court.
And in a simple code, while Dodge Challenger is not the best in saving the environment and I think
the worst level is, gee, so I will give it a G here and a semicolon.
OK, so finally we defined all our variables and as you can see, all of them are gray because they
are not used anywhere, but it will change very soon.
So in a new line here.
Start typing in system that Baudot Branton or use as or your team and hit enter, I'm going to go that
way.
So s o u t and one prints a string to system that out appears and it is selected, hit, enter.
And now as you can see, it is replaced with system that Outbrain time.
So double codes here 2000 18.
Dorje.
Challenger, SRT, three hundred and ninety two, so doubling this line.
And instead of this text, let's replace it with price.
Colin Espace and Euro Mark, you can also add it to the end of the text, I will show you how and here
after the double cotes plus and just stop and the variable name price and when it appears hit, enter.
OK, that's it.
Now, as you can see, prices here and price here is not great anymore.
You can also add another tax to the end of this by using plus again, double quotes and you can type
in euro if you cannot find the euro key on your keyboard.
OK, you know, I think this here.
And now let's move on to the next one, which is mileage, so doubling this line again.
And is the price going to have mileage and.
Here, mileage plus double quotes and KM or Mars, it is really up to you.
OK, now the next line is is damaged.
So here they call is damaged, damaged
corn, and here instead of milage and this text is damaged, registration number and cubic capacity
will be the next.
So here, registration, no registration number.
And here, registration number is variable name.
OK, now cubic capacity.
So, yeah, cubic capacity here.
Cubic capacity and plus double quotes and cesium.
Now let's bring out power and horsepower in the same line.
So here power.
Power plus kilowatt.
And they left parentheses here, plus the horsepower.
Plus, double quotes and HP and they write parentheses like CO2 emission is the next, so violating
this part here CO2 emission and leaving this part of the code.
IBM's CO2 emission plus an eye is mission missing from the air and space and gram per kilometer.
Now the emissions sticker and the energy efficiency category.
So doubling this line here again and here and mission.
Take.
Emissions sticker and hair left Prentice's energy efficiency
category.
Lower case.
Colin.
And plus, an energy efficiency category, close and double quotes and right parentheses also, let's
add a space here, too, and that's it.
OK, now let's move on to the next line here.
So the fuel consumption, so doubling this line and here.
Combined fuel consumption.
Colin Plus.
Here, fuel consumption combined and the leaf in this part of the code.
And here later, per 100 kilometers, the next three is going to be easy.
So just simply doubling this line and instead of combined, we're going to use urban world and changing
the variable name here to urban.
Doubling this line, yeah, extra urban.
And the text as well.
Here,
one more left.
Pressors.
Average fuel consumption here changing this.
Precise average, so three more variables left to go, number of previous owners, number of those and
a number of seats.
So here.
Bubbling face again.
Anything this.
Number of.
Previous oh, those.
And here, number of vehicle owners.
Doubling this line number of.
Those.
And finally, number of seats.
OK, so now we're done.
Let's go to the Green Arrow up here and select Ron.
So now you can see all the variables and the text we just tied in as an output here.
I know it was a bit long.
Feel free to pause the video and take a break.
In the next lecture, I will show you how to convert a death type into another one.
Save the.