The next primitive data type is like.
And here I need to actually give this variable a name.
For example land value.
OK.
And then I'm going to actually assign a value to this variable.
OK.
Disvalue is actually a very large value and it's now showing me an error and it says this value is out
of range.
OK.
So as you can see here this long data type only hold of value between these two numbers.
OK.
You can not actually exceed the maximum value that they can assign to this variable.
Now what out the value of this variable for the console.
So just like in here system that's out of insulin.
And then inside the practices I just need to refer to the name of the variable and at the end of my
statement I just need to put in a semicolon and here or I forgot to actually comment out this line of
code here.
And if I run my project again it's gonna output the value of this variable to the console.
OK.
Now I want to actually talk about the autocomplete feature of the eclipse ID and this feature helps
you to write your code faster.
OK.
So now if you want to refer to the name of the last rowdier bell as you can see I just need to actually
press the control and space key on my keyboard at the same time.
OK.
So for example I just type in here l or and and then control plus space and then it's going to show
me some recommendations which I can choose the name of that variable.
OK.
So that's it for the autocomplete feature of Eclipse.
The next primitive data type is flawed.
OK.
So as you can see here I just need to specify the Data Type of my variable which is bloats the name
of my variable would be float decimal number and I assign a value to my body.
But as you can see here three point.
OK.
So as I said earlier in this tutorial.
Float data type is a single precision relative to its floating point and it can hold a value between
these two numbers.
OK.
Floating point numbers are numbers with a decimal point.
OK.
So as you can see here it's now showing an error.
So if I actually hover over the error area it says Type Mismatch cannot convert from double to float.
OK.
And here we need to add the letter F at the end of our value.
OK so in this way we are actually making this value of float value.
Otherwise the eclipse assumes that we are actually assigning a double value to our variable.
Ok so that's the reason that it's now showing us an error.
So we must add the letter F at the end of our value in order to make this value of load value.
OK so this is a very important point about bloats data type.
OK.
So if I add the letter F at the end of my value here as you can see the error is now gone.
And if I for example want to output the value of this variable to the console as you can see here I
just need to type in here system data out that princeling and then inside Apprentice's.
I just need to put in the name of the variable here.
OK.
And at the end I just need to put the semi-colon at the end of my statement.
And if I run my projects now it outputs the value of this variable to the console.
So let me comment out this line of code here.
And if I run my project again as you can see this is the value of my offloads the small number ready.
OK.
The next primitive data type is double.
OK.
Double data type is like float.
OK.
So the name of my variable would be double decimal number and I assign a value to my body here.
OK so at the end I need to add the semicolon here.
And as you can see here the data type of my variable is Stobart.
OK.
And as I said earlier in the story all double data type is a double precision 64 with floating point.
And it can hold a value between these two numbers.
OK.
So double data type can be used for more precise numbers as you can see here.
OK.
So now I want to actually output the value of this variable to the console.
So just like in here system that out that insulin and that inside the apprentice's just referred to
the name of that variable.
OK.
Double the small number.
And at the end of your statement just put up a semicolon and then run your project.
Now as you can see here it's going to output the value of this variable to the console.
OK so the next primitive data type is called.
OK you can call it charge what I prepared to call it cost.
OK.
The name of the variable would be character and I'm going to assign a value to my variable as you can
see here.
OK.
For assigning values to car or chart variables we use single quotation marks.
OK earlier NDC Tauriel cartilages has had 16 bits and car data type is used for individual characters
such as the letters numbers punctuation and other symbols.
OK.
Now I want to actually output the value of this variable to the console.
So I just need to type in her system that out that princeling and inside the parenthesis just refer
to the name of that variable.
And if I run my projects now as you can see it outputs the value of this valuable to the console.
OK now I want to assign another value to this variable here.
OK so I just need to refer to the name of that variable and then I need to actually assign a value to
my variable here.
OK so now if I actually output the value of this variable to the console.
OK let's see what happens.
OK.
So here I just need to refer to the name of this variable.
And at the end I put a semicolon OK at the end of your statement.
So now I run my project as you can see the first value is this symbol.
OK.
And the second value as you can see here these dots here.
This is the last value that I assigned to my variable.
OK.
So let me actually show you another example.
So if I want to actually add another value to my valuable for example something like this why do you
if you want to output the value of this variable to the consul here.
OK let's see what happens again.
And at the end of your statement just put a semi-colon.
OK.
And then run your project as you can see the last value is this value that I assign to my variable here.
OK.
So this is a very important point about assigning values to variables.
OK so let me now actually again output the value of this character variable to the console and let's
see what happens.
System that out that princeling and then inside Apprentice's just referred to the name of this variable.
And at the end with a semicolon.
So as you can see here again it actually outputs this last value that I assigned to this variable.
OK.
So the last value that you assign to your variable is consistent throughout the lifetime of your variable.
In your application.
OK.
So this is a very important point that you should always consider about assigning values to variables.
And now let me give you another example about this concept.
OK.
So now if you want to for example assign another value to this lady here.
Ok for example this ampersand symbol.
OK.
So here I want to actually output the value of this variable to the console.
OK.
So just typing system that out that that print line and then inside the Prentice's just referred to
the name of the variable.
Here I use the autocomplete feature of the eclipse.
And at the end just with a semi-colon and run your project as you can see here the last value here is
the value that I assign to this value here.
OK this is the last value that we assigned to this value.
So the next primitive data type is Boulia.
OK.
As I said earlier this data type only holds either true or false values.
The name of the variable with B is ok.
I assign the value true to my variable here.
OK.
So as you can see boolean data type are these data type only holds are either true or false.
Ok so here I want to output the value of this variable to the console A-J system that's out that pre-incident
handed inside the apprentice's just referred to the name of this variable is.
OK.
So first let's actually comment how these lines of code.
Because I don't want to execute them.
OK.
So here I run my project as you can see it outputs the value true to the console.
OK.
Let me actually assign another value to this variable here.
So now I assign Faas as the value of this variable here.
OK.
So now I want to actually output the value of this variable to the console system that out that to.
And then inside Apprentice's just referred to the name of this variable and put a semicolon at the end
of your statement and run your project as you can see.