And then I need to refer to the name of this valuable face number so it's can actually switch between
the values of this office number variable.
So each time this group is going to be executed this variable is going to have a random number between
number one and number six.
OK.
So inside this inside the curly braces lets actually type in case one.
So this means that in case the value of this Faisalabad rowdier is number one plus plus number one OK
as you can see we created these valuables inside this class and here inside this method I am referring
to the name of those variables.
C++.
Number one means that increment the value of this number one variable and then our return that value
to me.
Okay great.
So if I were to actually write our number one plus plus in this way it is going to actually first of
all return the value of this number one to me and then it's going to increment this value.
So that's not what they wanted I want are this really about the value of this variable be increment.
And then I actually get that value OK or return that value.
OK so Case number two plus plus number to break.
OK.
Case number free plus plus number free semi-colon.
Break.
Case number four plus plus number four.
Break.
Case number five plus plus number five semicolon case number six plus plus number six.
OK great.
So now as you can see our switch statement is ready.
And let's actually after this is ending curly brace of this for loop as you can see here.
Let's actually continue adding our own quotes.
So here just typing takes the number one.
That said Text Number 1 OK plus two double quotes as you can see here.
This variable number one is of type integer.
So in order to put this variable inside these apprentices in order to assign this value to this set
take some effort that is related to this the number number one object.
We need to convert this value to a string value.
OK so itx the number two.
That said text number two plus two double quotes again ticks the number three.
That said text number free plus two double quotes DX the number four that said Text Number four plus
two double quotes the the number five that said Text Number five plus two double quotes 3x the number
six.
That said Text Number Six.
Plus two double quotes and or less actually on our project and see the results.
OK.
Now as you can see here our application is actually running on this emulator and our lets actually click
on this.
Roll the dice button here and lets see what happens.
As you can see here I click on this button here and it can actually take some time in order to calculate
some of those calculations.
And as you can see here now as you can see the results here.
OK.
And this number of times is built into this number one this number of times belongs to this number two
and so on.
OK so I'll talk more about a multi Freydon later in this course.
Nobody wants to wait when their application is actually freezing.
OK and no what no user wants their application to be freezed.
So you need to actually think of a way in order to solve that problem.
But for now remember that whenever that you actually click on the spot and its going to actually take
some time in order to calculate those expressions and then its going to show the results to you.
Blethering discourse I'll talk more about Monday-Friday in and I'll show you how you can make your applications
more dynamic so that your users start to actually see something whenever complex calculations is being
performed so that your users do not find that your application is actually freezing or it has been crashed.
OK.
So hopefully that makes sense.
Let's actually click on the spot and again and again it's going to take some time in order to calculate
those expressions.
So as you can see here again these values changed here.
Let's actually click on this button again.
Now as you can see again it's going to take some time.
So as you can see here now these numbers change again and so on.
OK.
Let's actually go inside this content underline minute example and then let's actually select all of
these are text views.
So if you are using a macro or six you need to hold the command key and then select all of these text
views.
And if you are using a Windows machine you need to actually hold the control key and then select these
text views here.
OK.
And the literature find the gravity attribute or as you can see here.
This is the gravity and tributes.
And let's actually check this check box that says Center underline horizontal.
OK so now let's actually run our project again and see what happens.
OK.
Now as you can see here our application is actually running on this emulator.
So let's actually click on this pattern here that says Roll the dice.
And then as you can see here it is actually taking some time because it's it's going to actually perform
some complex churchie relations as it can.
As you can see here and we need to actually give it a little time so as you can see here these values
are now here and are more readable.
OK.
So let's actually put the pictures of these Tice's here that are actually related to these numbers.
OK.
Number one number two and so on.
So on my desktop I have a folder here inside these are resources folder.
I have these images here.
OK.
So now I want to actually put Actually the copy and paste these images to my project.
So I just need to select those images that I want to actually copy and then I can just hold the command
key and then press on the letter key on my keyboard or I can just right click on them and then choose
Copy 6 items.
OK.
And let's actually go inside our project and then let's actually click on this view tool windows and
then our select project and here select this addressable folder and then you can either hold the command
key if you are using a microwave 6 and if you are using a Windows machine you need to actually hold
the control key OK and then press on the leader key on your keyboard OK and then click on OK.
As you can see here now these pictures are here inside these tribal folder.
So let's actually go back inside this main activity that dogfight here.
And then here inside this unclick Meffert after these lines of code that's actually referred to the
name of our pictures are UMG dice.
Number one that said Image resource.
OK.
Our dot triable dots dice one.
OK.
Again this actually refers to the name of our second image i n g.
Number two that said Image resource.
OK.
Our dot triable that dies
AMG dice number three that sets in resource are that Dr. Bell that is free.
IMT dice number four that said Image resource are that triable that dies for AMG dice.
Number five that said what image resource are that triable that dies for life.
And I m g dice number six.
That said a resource.
OK are that triable that dice 6.
So now as you can see these names are the names of our pictures.
OK.
As you can see here these pictures have names and we can actually refer to these names by actually referring
to this class are that triable.
This is the tribal folder and the picture that is inside of this tribal for that.