Parsing & Syntax Analysis

Answer & solution
Answer: B (no official key was published)
1. SLR states are sets of LR(0) items. Start with canonical LR(1) states for LALR and discard lookaheads to identify equal cores; merging those states leaves the reachable LR(0) cores. Different reduction entries in the tables do not create extra automaton cores.
2. SLR uses the canonical LR(0) item-state cores. LALR merges canonical LR(1) states that share an LR(0) core, leaving one state per such core. Thus their automata have the same number of states, n 1=n 2, B, under the conventional constructions, even though their reduction lookaheads and conflict behavior differ.