> From: Marshall Lochbaum
> Sent: Tuesday, 21 September 2010 10:53
>
> Not bad. I didn't know about _&{. before.
> As a side note,
> ,:^:(2...@$)
> forces arrays of any rank to rank 2. Dyadization is the obvious
> 2 ,:^:(-...@$) arr
Do you mean:
2 ,:@]^:(-...@$) array
Sometimes having {. as the inverse of ,:
,: b. _1
{.
might not be as desirable as ,/
2 ,:@]^:(-...@$) i. 2 3 4
0 1 2 3
4 5 6 7
8 9 10 11
lam=: ,: :. (,/)
2 l...@]^:(-...@$) i. 2 3 4
0 1 2 3
4 5 6 7
8 9 10 11
12 13 14 15
16 17 18 19
20 21 22 23
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm