This preview shows pages 1–2. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: G ABCD How short can the final derived terminal string be? Why? 7) (S10) A path in a parse tree has length x if it contains x variable nodes . Consider a parse tree T for a string x and a CNF grammar G with m variables. Suppose the longest path in T has length k. How long can this string x be? Suppose string x has length 2 m . How short can the longest path in T be? Take home review questions 1) What is a nullable variable? 2) How can we transform the following production so it fits CNF? S AbCD where A, C, and D are variables and b is a terminal character....
View Full Document
This note was uploaded on 07/25/2008 for the course CSE 460 taught by Professor Torng during the Fall '07 term at Michigan State University.
- Fall '07