> Roger's version wins by a long shot (2.2 vs 2.1 vs 1.7). It invokes fewer > verbs. The interesting thing is that it's collatzv that runs faster not > the code that follows - meaning that the interpreter is smart enough to use > integer arithmetic before we even get to *<.* ?!?
In Roger's definition of cnv, it uses an auxiliary with a helpful name: "m", containing a <. which, if my tests are right, is unneeded because of the same reason. ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
