COMPILER DESIGN

LEXICAL ANALYSIS

REGULAR EXPRESSIONS AND FINITE AUTOMATA

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
A Finite Automata recognizes
A
Context Free Language
B
Context Sensitive Language
C
Regular Language
D
Any Language
Explanation: 

Detailed explanation-1: -A language is a regular language if there is a finite automaton that recognizes it. For example, this machine recognizes the language of strings that have an even number of zeroes since any string that has an even number of zeroes will go from the start state to an accepting state.

Detailed explanation-2: -A regular language can be recognized by a finite automata, which is a simple machine model consisting of states, transitions, and an initial and final state. Conversely, every regular language can be expressed using finite automata., corresponding to an even number of 0’s in the string.

Detailed explanation-3: -Alternatively, a regular language can be defined as a language recognized by a finite automaton. The equivalence of regular expressions and finite automata is known as Kleene’s theorem (after American mathematician Stephen Cole Kleene).

There is 1 question to complete.