Help / Release / J 4.05 / ,./ Improved

From J Wiki
Jump to navigation Jump to search


>> << Pri JfC LJ Phr Dic Voc !: Rel NuVoc wd Help Release



,./ Improved

initial writing: 2000-00-00
last updated: 2004-10-26


The monad ,./ has been improved to execute in linear time. Time and space comparisons are as follows:

   ts   =: 6!:2 , 7!:2@]
   timer=: 6!:2

   c=: a.{~ ? 8000 17 11 $ #a.

J 4.05

   ts ',./ c'
0.0356291 2.09914e6

   12j8 ": ". 'timer '',./ x'' [ x=: ? 1e6 $~ 17 11,~' ,"1 ": ,. 100*1 2 4 8 16 
  0.00056907  0.00120267  0.00301630  0.00641981  0.01351596

J 4.04

   ts ',./ c'
71.8343 4.19642e6

   12j8 ": ". 'timer '',./ x'' [ x=: ? 1e6 $~ 17 11,~' ,"1 ": ,. 100*1 2 4 8 16 
  0.02501630  0.09891282  0.41983872  2.34642494  9.69553932



>> << Pri JfC LJ Phr Dic Voc !: Rel NuVoc wd Help Release