I especially like an improvement on you solution that removes the boxes in
the result. Notice, there is no need for explicit rank.

   ('+/~';'*/~') apply &:> 1 0
2 1
1 0

Thanks, again,

On Wed, Jul 26, 2017 at 9:09 AM, 'Pascal Jasmin' via Programming <
programm...@jsoftware.com> wrote:

> the difference between leaf (L:0) and each is that each implies a "_1 on
> unboxed items (actually for boxed items too).
>
>
> this also works
>
> ('+/~';'*/~') apply &:>"0 1 ] 1 0
>
>
> ('+/~';'*/~') apply &.>"0 1 < 1 0
>
>
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to