(|. i:) 4
0 1 2 3 4 _4 _3 _2 _1
   
Cheers, bob

> On Dec 12, 2018, at 7:50 AM, Raul Miller <[email protected]> wrote:
> 
>   Foo=:/:3|*
>   Foo i:4
> 0 1 2 3 4 _4 _3 _2 _1
> 
> Thanks,
> 
> -- 
> Raul
> On Wed, Dec 12, 2018 at 10:27 AM R.E. Boss <[email protected]> wrote:
>> 
>> That's what I found for the following problem: given an array if numbers, 
>> sort them in a way that the non-negative ones come first in ascending (or 
>> descending) order, followed by the negatives ones in ascending (or 
>> descending) order.
>> Elegance is a prerequisite.
>> 
>>   Foo i:4
>> 0 1 2 3 4 _4 _3 _2 _1
>> 
>> 
>> R.E. Boss
>> 
>> 
>> 
>> ----------------------------------------------------------------------
>> For information about J forums see http://www.jsoftware.com/forums.htm
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm

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

Reply via email to