00:01
So before jumping to the problem, we would go over a set of production p.
00:07
So s can be right as a -b -s, s can write as b -c -s, s can be right as b -b -s, s can be right as b -b -s, s can be right as a, and s can be right as c -b.
00:19
So for string a, we have b -c -b -b -a.
00:27
So start with s and then use p to derive the string.
00:32
As bcs.
00:35
Bcs can be right as bcbbs.
00:39
Bcbbs can be right as bcbba.
00:45
So we know that if the production step s can be right as v1, v2, dot, dot, v and s.
00:53
So the children of s would be v1, v2, dot, dot, bn, and s.
01:09
So use the children's of s, we can now write the derivation tree.
01:19
Start with s, we have s write as b, c, s, s is right as b, c, s, s, and this s has a children's of a.
01:33
So for part b, our b is slightly longer, we have b, b, c, oh, b, b, b, b, b, b, b, b, b, b, remember to count how many element bbbc, bba, bba, start with s, and then use p to derive the string.
01:52
So s is pbs, bbs is bbbbb -cs...