Hi, Welcome to the J forums. I would like to help, but I don't understand what you are asking. Perhaps others will understand better.
By *in*, do you mean the "Member in" verb? http://code.jsoftware.com/wiki/Vocabulary/edot On my pretty old spec 32-bit machine: a =: ? #~ 10000000 NB. 10 million random ints b =: 1000}. ? #~ 10000000 NB. (10 million - 1000) random ints timespacex ' a e. b' 0.210506 3.35551e7 I get 211 milliseconds. -------------------------------------------- On Tue, 12/6/16, Abi <[email protected]> wrote: Subject: [Jprogramming] in function which beats the benchmark To: [email protected] Date: Tuesday, December 6, 2016, 6:45 PM Hi, I am new to J. Can someone implement the *in* function. I have tried various ways but cannot get to beat the benchmark of ~130 ms. list1: 0 til 10MM list2 : 1M till 10MM list2 *in* list1 The line above shows the in operator. Thanks. ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
