Consider the Deterministic Finite-state Automation (DFA) $$A$$ shown below. The DFA runs on the alphabet {0, 1}, and has the set of states {$$s,p,q,r$$}, with $$s$$ being the start state and $$p$$ being the only final state.
Which one of the following regular expressions correctly describes the language accepted by $$A$$?
Consider the following definition of a lexical token id for an identifier in a programming language, using extended regular expressions:
$$\mathrm{letter\to[A-Za-z]}$$
$$\mathrm{letter\to[0-9]}$$
$$\mathrm{id\to letter(letter\,|\,digit)^*}$$
Which one of the following Non-deterministic Finite-state Automata with $$\varepsilon $$-transmissions accepts the set of valid identifiers? (A double-circle denotes a final state)
Which of the following statements is/are CORRECT?
Consider the context-free grammar G below
$$\matrix{ S & \to & {aSb|X} \cr X & \to & {aX|Xb|a|b,} \cr } $$
where S and X are non-terminals, and a and b are terminal symbols. The starting non-terminal is S.
Which one of the following statements is CORRECT?