Just tried that and it adds .7 sec (returning the unsorted keys). The sort in the original takes around .7s. There are only 446 primes found at that point. Returning an array is about the same time as returning an unsorted R.
On Sun, Aug 5, 2018 at 10:28 PM, Monte Goulding via use-livecode < use-livecode@lists.runrev.com> wrote: > I’m fairly sure you could speed it up by continuing to add keys to p and > returning that instead of building the list R. > > > On 6 Aug 2018, at 1:24 pm, Brian Milby via use-livecode < > use-livecode@lists.runrev.com> wrote: > > > > I can speed it up by 10% just be replacing the "add 1 to" with "put true > > into". The first if would lose the ">0". A single pass went from 50s to > > 44s on my iMac. > > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode > _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode