Love it.
Vento in this lesson we are going to solve this quotient find the length of the string.
So what do we do.
We will make OK Barry let's to Gavin Gavin sizes ended and what do will take.
We will take a name as input and let's say we and put input ABC and then basically we will print the
land of our party.
So what is the length.
So our output should be food.
So the output of this length should be food simple.
And how this ABC will get stored.
So first I have a then I would love b c and d and then at the end we will have a special connection
that so that's how this ABC will get stored in the air.
And this Lent function so I will write the code for the Lent function.
So this Lent function should have done me that data full.
There are four characters simple so let's write the code so that this comment out everything
what do we get return type of my function.
It will be in danger because I have to write down Leland and let's say the name of the function is lent.
Now what it will take as input obviously it will take a character is input.
So let's take Eric Barry now valid take and put size or not.
So if you remember in the Andes variety we have two possible things to the function.
So one thing that we have to pass is actually the array and the second thing is actually we have to
pass the number of basically the size of the 80.
MARTIN Correct Barry do not have to do that divide because it lets say what is your input.
So this is E then B then C and then B.
So ABC and at the end do you have.
So because of this number correctly you do not need to pass the length of the essay.
What do you do you will just irate and you will stop as soon as you will encounter them.
So in this case therefore I take this.
So so how can you find the land.
So what I'm going to do.
So this is my input.
Then I have B I have C and then I have.
And at the end we have a special panel and this adds very long so the size of the area is actually hundred.
So this is index zero and this is a next 99.
So I will start iterating so I will go to E and I will check it is an alternate.
I will go to B.
It isn't a lot.
I wouldn't go to see it isn't that correct or not.
I wouldn't go to the.
It doesn't look like it or not.
And here I will stop.
So basically what I will do I will maintain account variable and I will simply do count plus plus.
And finally I will return the count.
So let me write the code.
Then we will write and how the code will look.
So initially zero correctness at present and then let the site read over the cake.
So I will start everything from index zero and here the condition will be I have to iterate vital input
of A is why didn't fortify is not naughty.
It goes to the null corrector very lightweight.
While I am not encountering the null corrector and what we have to do I will do count plus plus and
here I will have done my count
and now I have inquired my function so see out the name of the function is linked.
And I will pass the input Eddie correct.
So what will happen so if you will give them input.
So let's go ahead.
I'm giving the input ABC.
So your name is ABC.
So ABC will get printed and I'm getting the function lent and am passing ABC.
So this is lent function
I have it.
Then this is B.
This is C. This is D.
And the special character never corrected.
And then we have God which correct us.
So this is index 0.
And the last one is index 99.
Now this count is actually 0.
So count is 0.
Then you're either rating or Betty.
So from equal 0 start you will start from index 0 and your eye will move in this direction and you have
to move till you are not even counting the nine correctly.
So a what will happen countless less so current will become one then B.
So your current will become 2 then C so your count will become 3 then B.
So your current will become 4 And finally you will encounter the null character.
So as soon as the input of AI becomes it goes to an enigmatic that this condition will become false
and I will return count.
So the county's Ford and Ford is the right answer for ABC.
So let us test our program and let's see what that our code is working correct or not.
So the name is ABC.
So your name is ABC.
Your name is ABC and the number of campus is food.
So let us Sprint vented
so I'm printing the land and let's just one more time
so my name is coding.
So your name is coding and the Lent is 6 salvo code is working fine so in the next video we will discuss
more about correct errors.
I will see you there.
Bye bye.