FAFL Final Lecture 4.2
FAFL Final Lecture 4.2
Lecture 4.2
Deterministic Finite Automata
School of Computing and Information
Technology
Ms. Shruthi G
[email protected]
AY:2020-2021
OUTLINE
Lecture Discussion
q0 a qa b qab *q0 qa q0
Construct a DFA that accept the strings of a’s and b’s having at least one a.
Construct a DFA that accept the strings of a’s and b’s having exactly one a.
Construct a DFA that accept the Language L={awa| w € {a,b}*} (or) L={awa | w€
(a+b) n where n>=0.
Construct a DFA that accept the strings of 0’s & 1’s having three consecutive 0’s.
Construct a DFA that accept the strings of a’s and b’s having exactly 4 a’s.
Construct a DFA that accept the strings of a’s and b’s ending with ab (or) ba.
Construct a DFA that accept the strings of 0’s,1’s and 2’s beginning with 0
followed by odd numbers of 1’s and ending with 2.
Construct a DFA that accept the strings of a’s and b’s with atmost two consecutive
b’s.
Construct a DFA that accept the strings of 0’s and 1’s starting with atleast two 0’s
and ending with atleast two 1’s.
SUMMARY OF THE LECTURE
DFA
DFA
DFA accepting
accepting The Language
accepting strings that
strings that accepted and
strings that do not
containing rejected by
containing contain given
given the DFA
given Suffix Suffix/Prefix/
Substring
Substring
RESOURCES AND TASK
Optional and non-optional reading resources of the
Lecture
Optional Resources
• https://www.eecs.wsu.edu/~ananth/CptS317/Lectures/index.htm
Web • https://www.geeksforgeeks.org/theory-of-computation-automata-tutorials/
resources • https://www.tutorialspoint.com/automata_theory/automata_theory_introdu
ction.htm
Non-Optional Resources
Web • Construct DFA to accept binary strings that begin with 0 and end with
resources 1 and do not contain the substring 110 over an alphabet Ʃ = { 0, 1}.
Non-Optional Task
Web • Construct DFA for accepting binary strings which when converted to
resources decimal is a multiple of 2.
SUMMARY OF THE LECTURE
Reading resources for the next lecture
Topic of Next Lecture: DFA construction for various languages with varying String formats
• https://www.eecs.wsu.edu/~ananth/CptS317/Lectures/index.htm
Web • https://www.geeksforgeeks.org/theory-of-computation-automata-tutorials/
resources • https://www.tutorialspoint.com/automata_theory/automata_theory_introduc
tion.htm
Construct a DFA to accept strings that do not contain the substring λ over an alphabet {a, b}.
QUIZ
Questions from Lecture 4.1
1. The password to the admins account=”administrator”. The total number of
states required to make a password-pass system using DFA would be __________
A) 14 states B) 12 states
5. The language of a DFA that accept binary strings that do not have prefix λ
is _______________
A) Ʃ* B) Ʃ+
C) ɸ D) { λ }
6. The language of a DFA that accept binary strings that do not have
substring λ is _______________
A) ɸ B) { λ }
C) Ʃ* D) Ʃ+
QUIZ
Questions from Lecture 4.2
7. The language accepted by the 8. The language accepted by the
following DFA over Ʃ = { 0, 1} is following DFA over Ʃ = { 0, 1} is
0, 1 0, 1
q q
A) ɸ C) Ʃ+ A) ɸ B) Ʃ*