Consider the regular expression R over the alphabet {a, b}: Which of the…

2025

Consider the regular expression R over the alphabet {a, b}:

image.png

Which of the following regular expressions below describe the same language as R?

Attempted by 67 students.

Show answer & explanation

The regular expression R = (a*b)* + (b*a)* describes the language of all strings over {a, b}. The term (a*b)* generates any string that ends with 'b' or is empty, as it consists of blocks ending in 'b'. Similarly, (b*a)* generates any string that ends with 'a' or is empty. Since every non-empty string over {a, b} must end with either 'a' or 'b', the union of these two sets covers all possible strings, which is equivalent to (a+b)*.

Explore the full course: Isro