[Haskell-cafe] Problems interpreting

Bulat Ziganshin bulat.ziganshin at gmail.com
Mon Sep 18 08:15:52 EDT 2006


Hello Andrea,

Monday, September 18, 2006, 3:22:43 PM, you wrote:

> substitute e l1 l2= [c | c <- check_elem l1]

why not just

substitute e l1 l2= check_elem l1

? :)

>     where check_elem [] = l1

should be

     where check_elem [] = []

otherwise you just append second (backup? :) copy of original list to
result :)




-- 
Best regards,
 Bulat                            mailto:Bulat.Ziganshin at gmail.com



More information about the Haskell-Cafe mailing list