in reply to Re: How to flatten an x-dimensional array?
in thread How to flatten an x-dimensional array?

To Perl-ize this wonderful Lisp solution *grins*
sub flatten { return unless @_; my $val = shift; return flatten(@$val, @_) if UNIVERSAL::isa($val, 'ARRAY'); return $val, flatten(@_); }

------
We are the carpenters and bricklayers of the Information Age.

Don't go borrowing trouble. For programmers, this means Worry only about what you need to implement.