00:01
They want us to construct binary trees for these prefix codes that they give us.
00:06
All right, so let's go ahead and start with a here.
00:11
All right, so we have a.
00:15
So to code, the letter a is going to be 1 -1.
00:21
So we're going to start from up here, and we're going to have 0 .1.
00:26
And then here we could go to 0 or 1, but we just want to go towards 1.
00:32
So let's do that.
00:34
So we're going to place a down there.
00:36
Now for e, so that's just zero.
00:40
So we just have e here.
00:44
Then for t, that's going to be one.
00:47
And then we need to go zero and then one again.
00:52
So we're going to go to the right.
00:53
Place t there.
00:55
And then lastly for s.
00:57
So it's one, zero.
01:00
So we go to left and then again, zero.
01:02
Then we place s down there.
01:04
So this here would be that binary tree for our coding scheme for a.
01:10
And you can see it is a binary or a prefix coding because we really don't have any ambiguity since all of these are just leaves.
01:21
Okay.
01:24
Now, let's go ahead and do b.
01:31
So it says we're going to start with a being just one.
01:37
So we start up here.
01:39
We draw to the right one and then that's going to be a then for e that's going to be zero one so that means we need to start to left to go there for zero and then we'd go to the right for one and so then we'd place e here so for t it says we're going to go zero and then one and so then we place t right there and so then we place t right there and and then s, so we need to do 0, 3 times...