19 May
2011
19 May
'11
11:52 p.m.
By the way, you don't need the "flip" function. map (** 3) [0,1..10] [ x ** 3 | x <- [0,1..10]] The section (** 3) will figure out on which side to put the argument/operand. See http://www.haskell.org/haskellwiki/Section_of_an_infix_operator 2011/5/19 <jianqiuchi@gmail.com>:
OK, I see. Thanks a lot.
Cheers, =)
,Felipe Almeida Lessa <felipe.lessa@gmail.com>撰写:
On Thu, May 19, 2011 at 11:05 AM, jianqiuchi@gmail.com> wrote:
I have a question about the cost of list comprehension and map function.
1. [x ** 3 | x 2. map (flip (**) 3) list
-- -- Regards, KC