formal language L
This commit is contained in:
parent
ab8ed1c73c
commit
9233edfb4b
3 changed files with 170 additions and 9 deletions
|
@ -13,15 +13,16 @@ data AlphaM
|
|||
type StringM = [AlphaM]
|
||||
|
||||
instance Language AlphaM where
|
||||
infer0 = [[M, I]]
|
||||
isWellFormed (M:_) = True
|
||||
isWellFormed _ = False
|
||||
|
||||
axiom0 = [[M, I]]
|
||||
infer1 =
|
||||
[ mRule1
|
||||
, mRule2
|
||||
, mRule3
|
||||
, mRule4
|
||||
]
|
||||
infer2 = []
|
||||
infer3 = []
|
||||
|
||||
-- RULE I: If you possess a string whose last letter is I, you can add on a U at the end.
|
||||
mRule1 :: StringM -> [StringM]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue