performance measurements imply that it doesn't duplicate it,

a =. |. 4 }. i.63
20 timespacex 'a { +: ^: (<63 ) 2' 
2.168e_5 40832 
20 timespacex ' +: ^: (a ) 2' 
1.944e_5 38144 
20 timespacex ' +: ^: (63 ) 2' 
5.648e_6 1536 


these results don't differ by much, but surprised that they do differ.

200 timespacex ' +: ^: (63 3) 2' 
1.00992e_5 12160 
200 timespacex ' +: ^: (63 62) 2' 
9.92639e_6 12032



>F^:(5 3) y 
>does not do any calculation for the '3' ?


> yes its efficient, simply collecting the results of each iteration
> while the function is applied to the "last value".
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to