Thank you all. I am satisfied with all your inputs. Tope
On Fri, Feb 22, 2008 at 7:17 AM, Christian Maeder <[EMAIL PROTECTED]> wrote: > TOPE KAREM wrote: > > Thanks. My question is whether it can call a function (say map) > > previously defined elsewhere in the program. Same goes for filter. > > I'm still not sure what to answer. If map and filter were user defined > functions they may occur anywhere in your current module (or must be > imported) and you can apply any argument in scope (of proper type). > > You could i.e. apply "(if <cond> then map else filter)" to "id" > which is the same as "if <cond> then map id else filter id" > > C. > > > On Fri, Feb 22, 2008 at 6:04 AM, Christian Maeder > > <[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>> wrote: > > I'm not sure what you're asking, but exp1 and exp2 may have (the > same) > > function type: > > > > if <cond> then map else filter :: (Bool -> Bool) -> [Bool] -> [Bool] > >
_______________________________________________ Haskell-Cafe mailing list [email protected] http://www.haskell.org/mailman/listinfo/haskell-cafe
