Change e letters to i in words: Difference between revisions
Content added Content deleted
Line 1,063: | Line 1,063: | ||
ieTwins s = |
ieTwins s = |
||
[ (w, twin) |
[ (w, twin) |
||
| w <- [x | x <- |
| w <- [x | x <- longWords, 'e' `elem` x], |
||
let twin = iForE w, |
let twin = iForE w, |
||
S.member twin lexicon |
S.member twin lexicon |
||
] |
] |
||
where |
where |
||
longWords = filter ((5 <) . length) (lines s) |
|||
lexicon = S.fromList |
lexicon = S.fromList $ filter ('i' `elem`) longWords |
||
iForE :: String -> String |
iForE :: String -> String |