Open In App
Related Articles

GATE | GATE CS 1997 | Question 44

Improve
Improve
Improve
Like Article
Like
Save Article
Save
Report issue
Report
Which one of the following regular expressions over {0,1} denotes the set of all strings not containing 100 as a substring? (A) 0* (1+0)* (B) 0*1010* (C) 0*1*01* (D) 0*(10+1)*

Answer: (D)

Explanation: According to given question, it should generate all other string / substring, but in given options :
  • (A) generates 100
  • (B) doesn’t generate 0
  • (C) doesn’t generate 1
Only option (D) is correct.

Quiz of this Question

Last Updated : 12 Jan, 2021
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads