Does an algorithm exist which can determine whether one regular language matches any input another regular language matches?

前端 未结 4 1989
礼貌的吻别
礼貌的吻别 2020-12-08 10:58

Let\'s say we have regular expressions:

  • Hello W.*rld
  • Hello World
  • .* World
  • .* W.*

I would like to minimize the number

4条回答
  •  庸人自扰
    2020-12-08 11:52

    Yes.

    The problem of equivalence of two regular languages is decidable.

    Sketch of an algorithm:

    • minimize both DFAs
    • check if they are isomorph

提交回复
热议问题