Regular Languages Equivalences
- 45Unfamiliar
- 0Learning
- 0Familiar
- 0Mastered
What is the central benefit of having multiple equivalent characterizations of regular languages?
What is the central benefit of having multiple equivalent characterizations of regular languages?
45 questions
- 1
What is the central benefit of having multiple equivalent characterizations of regular languages?
- A
They guarantee that every regular language has only one possible automaton
- B
They allow regular languages to be analyzed from several complementary perspectives
- C
They allow regular languages to recognize more languages than Turing machines
- D
They eliminate the need to define alphabets and input symbols
Correct answer
BThey allow regular languages to be analyzed from several complementary perspectives
Explanation
Equivalent characterizations make different properties easier to see from different perspectives. A property that is difficult to observe in one presentation may be obvious in another.
- A
- 2
Which statement correctly defines an alphabet in the mathematical treatment of formal languages?
- A
A collection of all accepted strings in a language
- B
A finite set of symbols used to form strings
- C
A program that processes symbols one at a time
- D
A sequence of states visited by an automaton
Correct answer
BA finite set of symbols used to form strings
Explanation
An alphabet is a finite set of characters or symbols. Strings, also called words, are formed from symbols in the alphabet.
- A
- 3
What is a mathematical word in the context of formal languages?
- A
A state that has an accepting transition
- B
A collection of all possible alphabets
- C
A finite string of symbols from an alphabet
- D
A symbol that appears in an alphabet exactly once
Correct answer
CA finite string of symbols from an alphabet
Explanation
In formal-language theory, a word is simply a string of symbols from an alphabet; it does not need to be an English word.
- A
- 4
What is a language in formal-language theory?
- A
Any set or collection of words
- B
Only the set of words accepted by a Turing machine
- C
A sequence of transitions between accepting states
- D
A finite set containing exactly one alphabet
Correct answer
AAny set or collection of words
Explanation
Any collection, or set, of words is called a language. The words need not have meanings in a natural language.
- A
- 5
When is a language called regular according to the content?
- A
When every word in it has the same length
- B
When it contains only symbols that occur in English
- C
When some deterministic finite-state automaton accepts exactly its words
- D
When it can be stored completely in a finite computer file
Correct answer
CWhen some deterministic finite-state automaton accepts exactly its words
Explanation
A language is regular exactly when it is defined or recognized by a deterministic finite-state automaton.
- A
- 6
What does the word 'finite' emphasize in a finite-state automaton?
- A
The machine must accept a finite number of words
- B
The machine can contain only one accepting state
- C
The machine can process only a finite number of inputs total
- D
The machine has only a finite amount of memory
Correct answer
DThe machine has only a finite amount of memory
Explanation
The defining limitation is that a finite-state automaton has a finite amount of internal memory, represented by finitely many states.
- A
- 7
Why must a finite-state automaton discard information as input continues to arrive?
- A
Its accepting states erase information after every transition
- B
Its transition function is allowed to inspect only the first symbol
- C
Its fixed memory cannot retain all information from an arbitrarily long input
- D
Its alphabet contains too few symbols to store the input
Correct answer
CIts fixed memory cannot retain all information from an arbitrarily long input
Explanation
Because the input may be much larger than the machine's fixed memory, the automaton must summarize the input and discard some details as it processes symbols.
- A
- 8
What happens to a finite-state machine when it revisits a state during a sufficiently long computation?
- A
It automatically enters an accepting state
- B
It stops because repeated states are not allowed
- C
It increases its memory to record the repeated transition
- D
It has repeated a configuration and cannot retain the full intervening history
Correct answer
DIt has repeated a configuration and cannot retain the full intervening history
Explanation
By the pigeonhole principle, a sufficiently long computation must revisit a state. Since the machine's memory is represented by its state, it cannot remember all events between the two visits.
- A
- 9
How does the keyboard-and-indicator-light model describe a finite-state automaton?
- A
The keyboard selects an accepting state before any input is processed
- B
The light records every symbol while the machine ignores its internal state
- C
The input symbols update internal state, and the final state determines whether the light is on
- D
The input symbols directly turn the light on without changing internal state
Correct answer
CThe input symbols update internal state, and the final state determines whether the light is on
Explanation
Each typed character changes the machine's state according to its transition rules. After the word is complete, the current state determines whether the indicator light is on.
- A
- 10
What does a finite-state automaton do while it is waiting for the next input symbol?
- A
It remains unchanged because it has no internal clock or external data source
- B
It resets itself to the start state after every pause
- C
It continuously changes states according to the amount of waiting time
- D
It analyzes all possible future inputs before receiving one
Correct answer
AIt remains unchanged because it has no internal clock or external data source
Explanation
The machine changes only when a new input symbol is supplied. It does not have an internal clock or another source of changing information.
- A
- 11
Why is a finite-state automaton deterministic?
- A
The machine accepts every word that reaches any state
- B
The machine uses an infinite amount of memory to avoid ambiguity
- C
Each state and input symbol determine exactly one next state
- D
Each input symbol can lead to several states chosen at random
Correct answer
CEach state and input symbol determine exactly one next state
Explanation
Determinism means that for every current state and particular input symbol, the next state is uniquely specified.
- A
- 12
What does an incoming arrow from outside a state diagram normally indicate?
- A
The state where the automaton begins processing each input word
- B
The state that receives symbols rejected by the machine
- C
The state that is visited after every input symbol
- D
The only state that can be accepting
Correct answer
AThe state where the automaton begins processing each input word
Explanation
The incoming arrow identifies the start state. In the example, the automaton starts in state 0.
- A
- 13
Why is the automaton reset before processing each new word?
- A
To allow the machine to add new states for each word
- B
To prevent the alphabet from changing during processing
- C
To ensure that the same word receives the same result independently of earlier inputs
- D
To ensure that every word begins in an accepting state
Correct answer
CTo ensure that the same word receives the same result independently of earlier inputs
Explanation
Resetting removes information from previous sessions and places the machine in its fixed start state, making its behavior well-defined and repeatable.
- A
- 14
What does a double-circled state represent in a finite-state automaton diagram?
- A
A state that contains an unlimited amount of memory
- B
An accepting state in which the indicator light is on
- C
A state that ignores all future input symbols
- D
A state that must be visited before the start state
Correct answer
BAn accepting state in which the indicator light is on
Explanation
A double circle marks an accept state. A word is accepted if the machine is in one of these states when the entire input has been read.
- A
- 15
What determines whether a word is accepted by a deterministic finite automaton?
- A
The state reached after the entire word has been processed
- B
Whether any intermediate state was visited more than once
- C
The first state visited after the first input symbol
- D
The total number of transitions taken regardless of destination
Correct answer
AThe state reached after the entire word has been processed
Explanation
The automaton processes the whole word and then accepts exactly when its final state is one of the designated accepting states.
- A
- 16
What is the role of a transition arrow labeled with a symbol?
- A
It marks the state from which the machine must restart
- B
It specifies the next state reached when that symbol is read
- C
It records the number of times the symbol has appeared
- D
It identifies the state that accepts every word containing that symbol
Correct answer
BIt specifies the next state reached when that symbol is read
Explanation
An arrow labeled with an input symbol describes how the machine changes state when that symbol is read from the arrow's source state.
- A
- 17
In the example automaton, what does reading the symbol c do?
- A
It moves the machine between states 0 and 1 depending on parity
- B
It moves the machine to state 2, which is a trap state
- C
It resets the machine to state 0
- D
It leaves the machine in its current state
Correct answer
BIt moves the machine to state 2, which is a trap state
Explanation
The example sends the machine to state 2 whenever it reads c. Once there, it remains trapped and cannot reach the accepting state.
- A
- 18
Why is state 2 called a trap state in the example?
- A
It is visited only when the input contains no symbols
- B
It is the only state from which the machine can accept immediately
- C
Once entered, no future input can lead to the accepting state
- D
It stores every symbol read before the machine enters it
Correct answer
COnce entered, no future input can lead to the accepting state
Explanation
After a c sends the machine to state 2, the machine stays there and cannot reach state 1, the accepting state.
- A
- 19
Which property characterizes the words accepted by the example automaton?
- A
They contain an even number of a symbols and at least one c symbol
- B
They contain an odd number of c symbols and any number of a symbols
- C
They contain an odd number of a symbols and no c symbols
- D
They contain exactly one b symbol and no a symbols
Correct answer
CThey contain an odd number of a symbols and no c symbols
Explanation
The automaton accepts when it ends in state 1. Reading a toggles between states 0 and 1, so an odd number of a symbols is required. Any c leads to the trap state 2.
- A
- 20
What effect does the symbol b have in the example automaton?
- A
It switches the machine between states 0 and 1
- B
It always moves the machine to state 1
- C
It sends the machine to the trap state 2
- D
It leaves the current state unchanged
Correct answer
DIt leaves the current state unchanged
Explanation
The b transition is a self-loop at each relevant state, so reading b does not change the machine's state.
- A
- 21
Why is the word
baaccepted by the example automaton?- A
The b moves the machine to state 1, and the a leaves it there
- B
The b leaves the machine in state 0, and the a moves it to accepting state 1
- C
The word ends in the trap state, which is also accepting
- D
The word contains no symbols that can change the machine's state
Correct answer
BThe b leaves the machine in state 0, and the a moves it to accepting state 1
Explanation
The machine starts in state 0. Reading b keeps it in state 0, and reading a moves it to state 1, which is accepting.
- A
- 22
Why is the word
baarejected by the example automaton?- A
The two a symbols toggle the machine back to nonaccepting state 0
- B
The first a sends the machine to the trap state 2
- C
The two a symbols are ignored because only b affects the machine
- D
The word is rejected because it contains fewer than three symbols
Correct answer
AThe two a symbols toggle the machine back to nonaccepting state 0
Explanation
Starting in state 0, the first a moves to state 1 and the second a moves back to state 0. Since state 0 is not accepting,
baais rejected. - A
- 23
Why is the word
bacbarejected by the example automaton?- A
The word contains an even number of a symbols
- B
The symbol b resets the machine before the final a
- C
The word ends in state 1, which is nonaccepting
- D
The symbol c sends the machine to trap state 2, preventing acceptance
Correct answer
DThe symbol c sends the machine to trap state 2, preventing acceptance
Explanation
When the machine reads c, it enters state 2. It remains trapped there, so the later a cannot move it to the accepting state.
- A
- 24
What is the purpose of a transition function, commonly written as δ?
- A
It maps every accepted word to the alphabet that generated it
- B
It maps a current state and input symbol to the next state
- C
It identifies which states are double-circled in a diagram
- D
It counts how many symbols remain unread in the input
Correct answer
BIt maps a current state and input symbol to the next state
Explanation
The transition function takes two inputs—the current state and the next input character—and returns the state reached after reading that character.
- A
- 25
For the example automaton, what does δ(1,c)=2 mean?
- A
Starting in state 2 and reading 1 leads to state c
- B
The machine reaches state 1 after reading two copies of c
- C
State 1 accepts exactly two copies of the symbol c
- D
Starting in state 1 and reading c leads to state 2
Correct answer
DStarting in state 1 and reading c leads to state 2
Explanation
The transition function's arguments are the current state and input symbol. Thus, δ(1,c)=2 means that c takes the machine from state 1 to state 2.
- A
- 26
How can a transition function be represented for algorithmic use?
- A
As a list containing only the accepting states
- B
As a diagram containing no labels on its arrows
- C
As a sentence describing the meaning of every accepted word
- D
As a table listing the next state for each state-symbol pair
Correct answer
DAs a table listing the next state for each state-symbol pair
Explanation
A transition table records the output of the transition function for each possible current state and input symbol.
- A
- 27
What is the alternative family-of-functions view of a deterministic finite automaton?
- A
There is one function from states to states for each input symbol
- B
There is one function from words to alphabets for each start state
- C
There is one function from inputs to memories for each possible word
- D
There is one function from symbols to symbols for each accepting state
Correct answer
AThere is one function from states to states for each input symbol
Explanation
Instead of using one two-argument transition function, one can define a separate state-to-state function for each input symbol.
- A
- 28
In the example's family-of-functions representation, what does the function for a do?
- A
It sends every state to state 2
- B
It swaps states 1 and 2 while leaving state 0 unchanged
- C
It leaves every state unchanged
- D
It swaps states 0 and 1 while leaving state 2 unchanged
Correct answer
DIt swaps states 0 and 1 while leaving state 2 unchanged
Explanation
Reading a toggles between states 0 and 1, while state 2 remains state 2.
- A
- 29
In the example's family-of-functions representation, what does the function for b do?
- A
It swaps states 0 and 1
- B
It is the identity function on the set of states
- C
It sends every state to the accepting state
- D
It sends every state to state 2
Correct answer
BIt is the identity function on the set of states
Explanation
The b transition leaves the current state unchanged, so its state-to-state function is the identity function.
- A
- 30
In the example's family-of-functions representation, what does the function for c do?
- A
It swaps states 0 and 1
- B
It leaves every state unchanged
- C
It sends every state to state 0
- D
It sends every state to state 2
Correct answer
DIt sends every state to state 2
Explanation
The example specifies that reading c always produces state 2, regardless of the current state.
- A
- 31
Which ordered collection contains the standard components of a deterministic finite automaton?
- A
States, accepting words, stack, transition history, and input length
- B
Alphabet, states, start state, transition function, and accepting states
- C
Start state, natural-language definition, tape, clock, and output alphabet
- D
Alphabet, words, memory tape, output program, and clock
Correct answer
BAlphabet, states, start state, transition function, and accepting states
Explanation
A deterministic finite automaton is characterized by its finite alphabet, finite set of states, start state, transition function, and set of accepting states.
- A
- 32
What restriction is placed on the alphabet and state set in the standard finite-state model?
- A
The alphabet is finite, but the state set must be infinite
- B
Both the alphabet and the set of states are finite
- C
Both the alphabet and the state set must be infinite
- D
The state set is finite, but the alphabet must contain every possible string
Correct answer
BBoth the alphabet and the set of states are finite
Explanation
The standard model under discussion uses a finite alphabet and finitely many internal states.
- A
- 33
How many accepting states may a deterministic finite automaton have?
- A
Exactly one state in every automaton
- B
At least two states in every automaton
- C
Only the start state
- D
Any subset of its states, including none or multiple states
Correct answer
DAny subset of its states, including none or multiple states
Explanation
The accepting states form any subset of the state set. An automaton may have zero, one, or many accepting states.
- A
- 34
How does the graph-path perspective characterize an accepted word?
- A
It corresponds to a path from the start state to an accepting state
- B
It corresponds to a path that begins at an accepting state
- C
It corresponds to a path that visits every state exactly once
- D
It corresponds to a path containing only self-loops
Correct answer
AIt corresponds to a path from the start state to an accepting state
Explanation
Each input word determines a path through the state graph. The word is accepted when that path begins at the start state and ends at an accepting state.
- A
- 35
What is the main contrast between finite-state automata and Turing machines in the content?
- A
Finite-state automata are nondeterministic, whereas Turing machines are always deterministic
- B
Finite-state automata use symbols, whereas Turing machines cannot process symbols
- C
Finite-state automata accept languages, whereas Turing machines cannot perform computation
- D
Finite-state automata have explicitly finite memory, whereas Turing machines model effectively unlimited memory
Correct answer
DFinite-state automata have explicitly finite memory, whereas Turing machines model effectively unlimited memory
Explanation
Finite-state automata explicitly have finite memory. Turing machines are an abstraction with an effectively infinite tape, allowing them to model computations with as much memory as needed.
- A
- 36
Why can an ordinary computer theoretically be viewed as a finite-state system?
- A
A computer can process only finite alphabets, so its memory must be infinite
- B
A computer with a fixed number of bits has finitely many possible memory configurations
- C
A computer has no memory and therefore has only one state
- D
A computer's memory configurations are determined by the number of input words
Correct answer
BA computer with a fixed number of bits has finitely many possible memory configurations
Explanation
If a computer has a fixed number of bits, each bit has two possible values, giving a finite number of possible configurations—specifically, 2n for n bits.
- A
- 37
Why might a real computer behave more like a finite-state automaton when processing a sufficiently large data set?
- A
Its processor automatically gains an infinite tape for large inputs
- B
Its alphabet becomes infinite after the data set reaches a certain size
- C
Its fixed memory eventually becomes insufficient, forcing it to discard information
- D
Its states become nondeterministic when the input exceeds memory capacity
Correct answer
CIts fixed memory eventually becomes insufficient, forcing it to discard information
Explanation
Real computers have finite memory. For data sets large enough to exceed that memory, the computer must summarize or discard information, resembling a finite-state system.
- A
- 38
Why are very small finite-state automata easier to analyze than a desktop computer modeled as an automaton?
- A
Small automata are the only systems that have accepting states
- B
Desktop computers cannot be represented by transition functions
- C
All states and transitions of a small automaton can be visualized at once
- D
Small automata use infinite memory, making their behavior simpler
Correct answer
CAll states and transitions of a small automaton can be visualized at once
Explanation
A small automaton has a manageable number of states and transitions, so its complete state diagram can be inspected. A computer would have an enormous number of possible configurations.
- A
- 39
What kind of real-world data-processing situation is finite-state computation intended to abstract?
- A
A program must preserve every input symbol for later analysis
- B
A stream of data is much larger than the available internal memory
- C
A system receives no input but changes according to an internal clock
- D
A small input is stored permanently in unlimited memory
Correct answer
BA stream of data is much larger than the available internal memory
Explanation
Finite-state systems model situations in which data streams are large relative to available memory, requiring the system to retain only selected information.
- A
- 40
How can a computer program resemble a finite-state automaton?
- A
It changes memory only when the input file reaches its end
- B
It chooses transitions randomly and never uses a fixed start configuration
- C
It stores the complete input without modifying any internal variables
- D
It initializes finite memory, repeatedly reads input, updates that memory, and produces a yes-or-no result
Correct answer
DIt initializes finite memory, repeatedly reads input, updates that memory, and produces a yes-or-no result
Explanation
A finite-state-style program declares bounded variables, initializes them, reads input in a loop, updates its memory based on each character, and can eventually return a Boolean result.
- A
- 41
What does the end-of-file condition do in the program analogy?
- A
It expands the program's memory to store the entire input
- B
It resets all variables to their initial values after each character
- C
It changes the current state to the accepting state automatically
- D
It signals that no more input characters remain to be processed
Correct answer
DIt signals that no more input characters remain to be processed
Explanation
The input-processing loop continues until it reaches EOF, meaning the end of the input has been reached.
- A
- 42
Why do fixed-size integer variables contribute to a finite-state interpretation of a program?
- A
Fixed-size integers guarantee that every input will be accepted
- B
Each integer can store an arbitrarily long input without loss of information
- C
Each variable has only finitely many possible values and therefore finitely many configurations
- D
Integer variables prevent a program from processing input sequentially
Correct answer
CEach variable has only finitely many possible values and therefore finitely many configurations
Explanation
A fixed-size integer has a bounded range of values. Arrays of such integers also have finitely many configurations, so the program's memory can be modeled as a finite set of states.
- A
- 43
What limitation arises when a fixed-size digit-counting program processes counts larger than its numeric range?
- A
Its recorded counts can become inaccurate because the variables cannot represent arbitrarily large values
- B
The alphabet of input digits becomes invalid
- C
The program automatically becomes a Turing machine with infinite memory
- D
The program must stop before reading any further character
Correct answer
AIts recorded counts can become inaccurate because the variables cannot represent arbitrarily large values
Explanation
Fixed-size integers have finite maximum values. If a count exceeds that range, the stored count cannot accurately represent the true number of occurrences.
- A
- 44
In the program analogy, what corresponds most closely to the start state of an automaton?
- A
The initial values assigned to the program's memory variables
- B
The complete list of characters in the input alphabet
- C
The EOF condition at the end of the input
- D
The final Boolean value returned by the program
Correct answer
AThe initial values assigned to the program's memory variables
Explanation
Initializing the variables establishes the program's initial memory configuration, analogous to placing an automaton in its start state.
- A
- 45
What would make an input-processing program function like a recognizer for a language?
- A
It would return true or false based on its final memory state after reading the input
- B
It would allocate unlimited memory before reading the first character
- C
It would accept an input whenever any intermediate state is reached
- D
It would print every input character without changing memory
Correct answer
AIt would return true or false based on its final memory state after reading the input
Explanation
A finite-state recognizer processes the input, examines its final state, and returns a Boolean decision indicating whether the input belongs to the language.
- A

Ask anything
We've read this whole study set, so questions about it get the best answers.