Questions: Regular Languages: Definition and Characterization

5 questions to test your understanding

Score: 0 / 5
Question 1 Multiple Choice

Which of the following languages is NOT regular?

AThe set of all strings over {a, b} that contain the substring 'ab'
BThe set of all strings over {a, b} with even length
CThe set of strings of the form aⁿbⁿ where n ≥ 0 (equal numbers of a's followed by b's)
DThe set of all strings over {a, b} that begin with 'a'
Question 2 Multiple Choice

Why can no finite automaton recognize the language {aⁿbⁿ | n ≥ 0}?

ABecause DFAs cannot process strings that contain both a's and b's
BBecause regular expressions cannot use variables like n
CBecause recognizing the language requires remembering how many a's were read, and that count can grow without bound while a DFA has only finitely many states
DBecause the language is infinite, and finite automata can only recognize finite languages
Question 3 True / False

A nondeterministic finite automaton (NFA) can recognize languages that no deterministic finite automaton (DFA) can recognize.

TTrue
FFalse
Question 4 True / False

Regular languages are characterized by the ability to be recognized using only a constant amount of memory, regardless of how long the input string is.

TTrue
FFalse
Question 5 Short Answer

Explain in your own words why three seemingly different formalisms — DFAs, regular expressions, and right-linear grammars — all define exactly the same class of languages.

Think about your answer, then reveal below.