Okay, so the first thing we need to do is number the lines and

spe, talk about specific lines.

[SOUND]

Okay.

So, we come, the first thing we can do is first focus on the simplest lines, okay?

As I said, when we do learning time analysis we make that

big assumption that all, all individual operations.

Take fixed amount of time regardless of the size of the input.

So if I look at individual operations here for example, assignment eh,

comparison is K smaller than, than the size of the, these assignments.

This assignment here, this assignment and so on.

These are all, each one if them take one operation.

So, I can now start thinking about the numbe,

counting the number of operations here.

[SOUND] How many operations does this line take?

It takes one.

I'm assuming it takes one operation regardless of fixed amount of

time regardless of input size.

What do I mean by a fixed amount of time?

I'm going to count it as one.

Okay?

This line three here, line three is going to take also fixed amount of time.

I'm going to label it as one.

This line here is just one individual operation, one, one step.

This line, its path taking through, is going to take one.

This if statement here, I'm checking if this if this

edge is not in E, I will assume that it takes one operation here.

[SOUND] Is path takes false,

I'm assuming it takes one operation, okay?

And IsPath True, I'm going to ta, assume it takes one operation.

And return K is one operation, K plus 1 is one operation.

We need to adjust the numbers here, this is 13.

It's one operation.

And this is 14, one operation.

Okay?

Just to make sure

we can label [SOUND] okay?

So, we have 14 lines in the algorithm.

We started with the simplest ones.

Again, assignment, assignment here, assignment we are asking if it, it equal,

we're checking equality assignment, assignment, return and so on, okay?

So we're looking at these ones, actually we can be a bit more details.

Here it's not just assignment, we're adding a number and then assigning it.

So, we can say it is 2 here, and so on, okay?

But you know, in the, when we do the analysis,

we'll notice that one versus two is not going to make a difference.

Okay? Now we start looking at the other ones.

Okay? So we have a while loop here.

It's going to loop again, K starts at one, and it's at the size of V.

Remember, the input size is N and M, it has N nodes.

So this is going to be n, okay.

The size of V is N,

and K is going to go from 1 all the way to the last number before N.

So it's going to go to N minus 1.

So, K is going to take values 1, 2, 3, 4, until N minus 1.

So this is going to loop here or iterate N minus 1 times.

Okay?