This is an assignment of autometa theory for the programs of regular expression., Formulas and forms for Theory of Automata. Bahauddin Zakariya University, Multan
atika-asghar
atika-asghar

This is an assignment of autometa theory for the programs of regular expression., Formulas and forms for Theory of Automata. Bahauddin Zakariya University, Multan

3 pages
17Number of visits
Description
This is an assignment of autometa theory for the programs of regular expression.
20 points
Download points needed to download
this document
Download the document
Preview3 pages / 3
Download the document

Assignment # 03

Automata Theory Kleene’s Theorem Examples

Example 1

Solution:

private void button1_Click(object sender, EventArgs e) {

Regex validator = new Regex("[" "+b][[ab]*bb*[“” +a[a+b]*] +a[ba]* a[a+b]*] +a[ba]*a [a+b]*+ab[ab]*bb*["" +a[a+b]*]");

if (validator.Match(textBox1.Text).Success) MessageBox.Show("Valid String!"); else MessageBox.Show("In-Valid String!"); }

Example 2

Solution:

private void button1_Click(object sender, EventArgs e) { Regex validator = new Regex("a[ab]*b+ab[ba]*a");

if (validator.Match(textBox1.Text).Success) MessageBox.Show("Valid String!"); else MessageBox.Show("In-Valid String!"); }

no comments were posted
Download the document