$:@}.`{.@.(6<{.) +: 2 1 3 2 4 5 2
8

much slower

   {.@(}.^:(6>:{.)^:_@: +:) 2 1 3 2 4 5 2
8

But I prefer Raul's solution.



On 17-11-13 03:38, Pascal Jasmin wrote:
I spent some time describing the application.  You can also think of the 
application as search every web page on every ipv4 until the first interesting 
thing is found.  Maybe I care about a 2nd interesting thing, maybe I don't.  
But I'd like to see the first before I ask for another, and the approach of 
finding them all and then returning the first is not practical.

The explicit version I provided is not unworkable.  I was hoping that there is 
a version with {. and $:@:}.


----- Original Message -----
From: Raul Miller <[email protected]>
To: Programming forum <[email protected]>
Cc:
Sent: Saturday, November 16, 2013 8:56:03 PM
Subject: Re: [Jprogramming] repeatuntil and repeat while tacit definitions      
possible?

    ({~ 1 i.~ 6 < ]) +: 2 1 3 2 4 5 2
8
    ({.~ 1 i.~ 6 < ]) +: 2 1 3 2 4 5 2
4 2 6 4

Now you might argue that this is not the same thing. But it is the same result.

It's just faster to compute this way. And, ok, I understand that speed
is not necessarily desirable. But I think in this case you might want
to just use a different language.


--
Met vriendelijke groet,
@@i = Arie Groeneveld

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to