... but the timings aren't so good - perhaps that
doesn't matter.
ts'<.`0:@.(0=*)("0) (1000000$i:5)--:ct'
0.995482 5.82e7
NB. similar avoiding the "0 test:
ts'(<.*0:~:*) (1000000$i:5)--:ct'
0.279156 3.04111e7
NB. there must be some optimisation here?!
ts'(**<.@:**)(100000$i:5)--:ct'
0.0108771 3.67232e6
M
bill lam wrote:
bill lam wrote:
I also try <.`0:@.(1:=>:)("0)
another candidate may be <.`0:@.(0:=*)("0) as monad * is tolerant when comparing
with 0.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm