0
$\begingroup$

How can one design a regular expression for given string in title ?

Also how can we draw DFA of that regular expression?

I've tried many expressions but couldn't succeed, please help.

$\endgroup$
1
$\begingroup$

The regular expression would be like $(0 + 1)^*010(0 + 1)^*01 + (0 + 1)^*0101$. Transformation of a regular expression to a DFA has a well-defined algorihtms, and you can find them in the resources.

$\endgroup$
0
$\begingroup$

enter image description here

Not the best photo quality , but it will work. I think this DFA is the one but correct me if i'm wrong. :)

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.