How would you make a flat?
a=.1;2;('a';'b';(1 2 3);11 12);3;4;5
;.a
;.((<1),(<2),(<'a';'b';1 2 3;11 12),(<3),(<4),<5)
2009/9/19 a b <[email protected]>:
> Apparently J has no "enlist" (APL) function to remove all nesting and make a
> structure completely flat? I searched for such a function for hours in
> vain. I also googled for hours - nothing.
>
> I ended up concocting my own, but it is error-prone, and not very nice. I'd
> like something better. Can someone help with either a built-in which I've
> obviously missed, or the couple of character strokes that I'm sure it takes
> to get the job done?
>
> Thanks.
>
>
>
>
>
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>
--
Björn Helgason, Verkfræðingur
Fugl&Fiskur ehf,
Þerneyjarsundi 23, Hraunborgum
Po Box 127,801 Selfoss ,
t-póst: [email protected]
gsm: +3546985532
Landslags og skrúðgarðagerð, gröfuþjónusta
http://groups.google.com/group/J-Programming
Tæknikunnátta höndlar hið flókna, sköpunargáfa er meistari einfaldleikans
góður kennari getur stigið á tær án þess að glansinn fari af skónum
/|_ .-----------------------------------.
,' .\ / | Með léttri lund verður |
,--' _,' | Dagurinn í dag |
/ / | Enn betri en gærdagurinn |
( -. | `-----------------------------------'
| ) | (\_ _/)
(`-. '--.) (='.'=) ♖♘♗♕♔♙
`. )----' (")_(") ☃☠
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm