bug-apl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-apl] Non-bug: Help comparing solutions


From: Jay Foad
Subject: Re: [Bug-apl] Non-bug: Help comparing solutions
Date: Wed, 5 Mar 2014 10:18:55 +0000

On 5 March 2014 05:25, Elias Mårtenson <address@hidden> wrote:
> Referencing yesterday's discussion about ⍤, I realised that I can use it to
> get the indexes like this:
>
>       X
> ┌→─┐
> ↓xz│
> │zx│
> │ab│
> │ba│
> └──┘
>       ⍋⍤1 X
> ┌→──┐
> ↓1 2│
> │2 1│
> │1 2│
> │2 1│
> └───┘
>
>
> However, I can't figure out a good way to apply it to the original array.
> Really, what is th ebest solution to this problem?

      {⍵[⍋⍵]}⍤1 X

Jay.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]