Machine-translated by Google. Questions are authored in English.
Top

Discussion

The number of entries actually filled in a typical LL(1) table, compared with the total number of cells, is

  • A.a small fraction, most cells being error entries
  • B.almost all of them, since every token is legal somewhere
  • C.exactly one per row of the whole table
  • D.equal to the number of terminals in the grammar

Answer: A

Each production contributes entries only for the terminals in its FIRST set. The sparsity is what makes compressed representations attractive for large grammars. A grammar with many terminals produces a table that is almost entirely empty.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.