Terrence asked:

>    +/ @: +/"1 w
>  5 5 5 5

Henry responded:

>  +/ @: (+/"1) 

So long as the argument is a rank-2 array, this would also work:

           +/@:,  

and this is cute:

           +/^:2

in general:

           +/@:, -: +/^:(#@:$)
-Dan
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to