COMPILER DESIGN

LEXICAL ANALYSIS

REGULAR EXPRESSIONS AND FINITE AUTOMATA

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
Regular expression denote language which is accepted by finite automata
A
Yes
B
No
C
May be
D
Can’t say
Explanation: 

Detailed explanation-1: -A regular expression can be defined as a language or string accepted by a finite automata. We know that a finite automata consists of five touples Q, , , q0, F. Among them a Regular Expression is a string on , i.e. it will consist only with input alphabets. In short a Regular Expression is written as RE.

Detailed explanation-2: -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-3: -Finite automata represent exactly regular languages, and another way to describe regular languages is through regular expressions. As an example, (deterministic) finite automata can accept all and only the strings of 0’s and 1’s that have the sequence 01 somewhere in the string.

There is 1 question to complete.