# RE for starting with 1 having zero or multiple even 1’s

## , defined over{1}

Regular Expression = (11)*

## Rule

All strings starting with 1 and then after first one having zero or multiple even 1’s must be accepted and all other strings must be rejected by our Regular Expression.

# Regular Expression = 1(11)*

## Reject able strings (not part of the language)

These strings are not part of the given language and must be rejected by our Regular Expression.

• 3 strings of length 1 = {No string}
• 3 strings of length 2 = {11}
• 3 strings of length 3= {no string}
• 3 strings of length 4 = {1111}
• 3 strings of length 7 = {no string}
• 3 strings of length 10 = {1111111111}
• 3 strings of length 15 = {no string}
• 3 strings of length 20 = {11111111111111111111}
• 3 strings of length 25 = {no string}
• Many More similar strings.

## Acceptable strings (part of the language)

These strings are part of the given language and must be accepted by our Regular Expression.

• 3 strings of length 1 = {1, no more strings}
• 3 strings of length 2 = {No string}
• 3 strings of length 3= {111, no more strings}
• 3 strings of length 4 = {No Strings}
• 3 strings of length 7 = {1111111, no more strings}
• 3 strings of length 10 = {NO Strings}
• 3 strings of length 15 = {111111111111111, no more strings}
• 3 strings of length 20= {No Strings}
• 3 strings of length 25= {1111111111111111111111111}
• Many More similar strings.

## Rule

All strings starting with a and then after first one having zero or multiple even a’s must be accepted and all other strings must be rejected by our Regular Expression.

# Regular Expression = a(aa)*

## Reject able strings (not part of the language)

These strings are not part of the given language and must be rejected by our Regular Expression.

• 3 strings of length 1 = {No string}
• 3 strings of length 2 = {aa}
• 3 strings of length 3= {no string}
• 3 strings of length 4 = {aaaa}
• 3 strings of length 7 = {no string}
• 3 strings of length 10 = {aaaaaaaaaa}
• 3 strings of length 15 = {no string}
• 3 strings of length 20 = {aaaaaaaaaaaaaaaaaaaa}
• 3 strings of length 25 = {no string}
• Many More similar strings.

## Acceptable strings (part of the language)

These strings are part of the given language and must be accepted by our Regular Expression.

• 3 strings of length 1 = {a, no more strings}
• 3 strings of length 2 = {No string}
• 3 strings of length 3= {aaa, no more strings}
• 3 strings of length 4 = {No Strings}
• 3 strings of length 7 = {aaaaaaa, no more strings}
• 3 strings of length 10 = {NO Strings}
• 3 strings of length 15 = {aaaaaaaaaaaaaaa, no more strings}
• 3 strings of length 20= {No Strings}
• 3 strings of length 25= {aaaaaaaaaaaaaaaaaaaaaaaaa}
• Many More similar strings.

## Tutorial: Regular Expression

A detailed tutorial of the regular expression is here in the link of regular expression tutorial. This page contains the practice questions of regular expressions with solutions.

Tutorial covering the topics

• Give a regular expression.
• Describe the strings of the regular expression.
• write a regular expression.
• create all strings from regular expression.
• Generate all strings from regular expression.
• Extract all strings from regular expression.
• Find all strings from regular expression.
• Examples of regular expression.