1
00:00:02,430 --> 00:00:02,950
Love it.

2
00:00:02,950 --> 00:00:07,930
Vento in this lesson we are going to solve this quotient find the length of the string.

3
00:00:07,930 --> 00:00:09,250
So what do we do.

4
00:00:09,280 --> 00:00:15,890
We will make OK Barry let's to Gavin Gavin sizes ended and what do will take.

5
00:00:15,900 --> 00:00:23,160
We will take a name as input and let's say we and put input ABC and then basically we will print the

6
00:00:23,220 --> 00:00:26,570
land of our party.

7
00:00:26,760 --> 00:00:27,570
So what is the length.

8
00:00:27,600 --> 00:00:29,140
So our output should be food.

9
00:00:29,340 --> 00:00:32,790
So the output of this length should be food simple.

10
00:00:32,820 --> 00:00:35,360
And how this ABC will get stored.

11
00:00:35,400 --> 00:00:41,910
So first I have a then I would love b c and d and then at the end we will have a special connection

12
00:00:41,990 --> 00:00:46,650
that so that's how this ABC will get stored in the air.

13
00:00:47,190 --> 00:00:51,710
And this Lent function so I will write the code for the Lent function.

14
00:00:51,710 --> 00:00:55,060
So this Lent function should have done me that data full.

15
00:00:55,390 --> 00:01:04,960
There are four characters simple so let's write the code so that this comment out everything

16
00:01:11,790 --> 00:01:14,150
what do we get return type of my function.

17
00:01:14,150 --> 00:01:20,460
It will be in danger because I have to write down Leland and let's say the name of the function is lent.

18
00:01:20,540 --> 00:01:24,980
Now what it will take as input obviously it will take a character is input.

19
00:01:25,130 --> 00:01:30,750
So let's take Eric Barry now valid take and put size or not.

20
00:01:30,900 --> 00:01:35,730
So if you remember in the Andes variety we have two possible things to the function.

21
00:01:35,730 --> 00:01:40,470
So one thing that we have to pass is actually the array and the second thing is actually we have to

22
00:01:40,470 --> 00:01:43,620
pass the number of basically the size of the 80.

23
00:01:43,770 --> 00:01:48,270
MARTIN Correct Barry do not have to do that divide because it lets say what is your input.

24
00:01:48,270 --> 00:01:52,240
So this is E then B then C and then B.

25
00:01:52,340 --> 00:01:55,080
So ABC and at the end do you have.

26
00:01:55,790 --> 00:02:00,310
So because of this number correctly you do not need to pass the length of the essay.

27
00:02:00,350 --> 00:02:06,110
What do you do you will just irate and you will stop as soon as you will encounter them.

28
00:02:06,830 --> 00:02:08,570
So in this case therefore I take this.

29
00:02:08,580 --> 00:02:11,400
So so how can you find the land.

30
00:02:11,420 --> 00:02:13,170
So what I'm going to do.

31
00:02:13,350 --> 00:02:15,990
So this is my input.

32
00:02:16,050 --> 00:02:18,780
Then I have B I have C and then I have.

33
00:02:19,200 --> 00:02:26,750
And at the end we have a special panel and this adds very long so the size of the area is actually hundred.

34
00:02:26,790 --> 00:02:29,930
So this is index zero and this is a next 99.

35
00:02:30,150 --> 00:02:35,880
So I will start iterating so I will go to E and I will check it is an alternate.

36
00:02:35,940 --> 00:02:36,950
I will go to B.

37
00:02:37,020 --> 00:02:37,870
It isn't a lot.

38
00:02:37,950 --> 00:02:40,350
I wouldn't go to see it isn't that correct or not.

39
00:02:40,350 --> 00:02:41,060
I wouldn't go to the.

40
00:02:41,070 --> 00:02:42,250
It doesn't look like it or not.

41
00:02:42,270 --> 00:02:43,620
And here I will stop.

42
00:02:45,300 --> 00:02:51,390
So basically what I will do I will maintain account variable and I will simply do count plus plus.

43
00:02:51,390 --> 00:02:53,610
And finally I will return the count.

44
00:02:55,160 --> 00:02:56,220
So let me write the code.

45
00:02:56,230 --> 00:02:59,620
Then we will write and how the code will look.

46
00:02:59,630 --> 00:03:08,000
So initially zero correctness at present and then let the site read over the cake.

47
00:03:08,140 --> 00:03:15,880
So I will start everything from index zero and here the condition will be I have to iterate vital input

48
00:03:15,880 --> 00:03:20,490
of A is why didn't fortify is not naughty.

49
00:03:20,540 --> 00:03:24,600
It goes to the null corrector very lightweight.

50
00:03:24,610 --> 00:03:33,450
While I am not encountering the null corrector and what we have to do I will do count plus plus and

51
00:03:33,450 --> 00:03:35,030
here I will have done my count

52
00:03:38,530 --> 00:03:43,220
and now I have inquired my function so see out the name of the function is linked.

53
00:03:45,650 --> 00:03:49,690
And I will pass the input Eddie correct.

54
00:03:49,760 --> 00:03:54,310
So what will happen so if you will give them input.

55
00:03:54,340 --> 00:03:55,240
So let's go ahead.

56
00:03:55,240 --> 00:03:57,350
I'm giving the input ABC.

57
00:03:57,970 --> 00:03:59,280
So your name is ABC.

58
00:03:59,330 --> 00:04:03,810
So ABC will get printed and I'm getting the function lent and am passing ABC.

59
00:04:03,880 --> 00:04:05,020
So this is lent function

60
00:04:07,970 --> 00:04:08,590
I have it.

61
00:04:08,610 --> 00:04:09,570
Then this is B.

62
00:04:09,660 --> 00:04:11,150
This is C. This is D.

63
00:04:11,760 --> 00:04:14,080
And the special character never corrected.

64
00:04:16,260 --> 00:04:18,210
And then we have God which correct us.

65
00:04:18,270 --> 00:04:19,600
So this is index 0.

66
00:04:19,740 --> 00:04:22,560
And the last one is index 99.

67
00:04:22,620 --> 00:04:24,620
Now this count is actually 0.

68
00:04:25,020 --> 00:04:28,710
So count is 0.

69
00:04:28,890 --> 00:04:31,280
Then you're either rating or Betty.

70
00:04:31,380 --> 00:04:37,710
So from equal 0 start you will start from index 0 and your eye will move in this direction and you have

71
00:04:37,710 --> 00:04:40,970
to move till you are not even counting the nine correctly.

72
00:04:41,220 --> 00:04:47,250
So a what will happen countless less so current will become one then B.

73
00:04:47,250 --> 00:04:52,470
So your current will become 2 then C so your count will become 3 then B.

74
00:04:52,620 --> 00:04:56,440
So your current will become 4 And finally you will encounter the null character.

75
00:04:56,670 --> 00:05:01,620
So as soon as the input of AI becomes it goes to an enigmatic that this condition will become false

76
00:05:02,490 --> 00:05:03,930
and I will return count.

77
00:05:03,930 --> 00:05:07,720
So the county's Ford and Ford is the right answer for ABC.

78
00:05:08,520 --> 00:05:13,020
So let us test our program and let's see what that our code is working correct or not.

79
00:05:17,700 --> 00:05:20,000
So the name is ABC.

80
00:05:20,280 --> 00:05:21,670
So your name is ABC.

81
00:05:21,720 --> 00:05:25,350
Your name is ABC and the number of campus is food.

82
00:05:25,410 --> 00:05:26,910
So let us Sprint vented

83
00:05:34,370 --> 00:05:37,710
so I'm printing the land and let's just one more time

84
00:05:40,580 --> 00:05:42,680
so my name is coding.

85
00:05:43,070 --> 00:05:51,440
So your name is coding and the Lent is 6 salvo code is working fine so in the next video we will discuss

86
00:05:51,440 --> 00:05:52,930
more about correct errors.

87
00:05:53,000 --> 00:05:53,950
I will see you there.

88
00:05:53,950 --> 00:05:54,310
Bye bye.
