Assignment 3 2025
Unique #:
Due Date: 2025
Detailed solutions, explanations, workings
and references.
+27 81 278 3372
, QUESTION 1
CFG for L₁ = (aa)*
S1 → aaS1 | Ʌ
This can generate zero occurrences of aa or one or more occurrences of aa as
required.
CFG for L₂ = (a + b)ab(a + b)
S2 → XabY
X → aX | bX | Ʌ
Y → aY | bY | Ʌ
By Theorem 37, CFG for L₁L₂:
S → S1 S2
S1 → aaS1 | Ʌ
S2 → XabY
X → aX | bX | Ʌ
Y → aY | bY | Ʌ
Varsity Cube 2025 +27 81 278 3372