Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re^7: Array_ref into Array_ref Help.

by lostjimmy (Chaplain)
on Apr 22, 2009 at 19:52 UTC ( [id://759391]=note: print w/replies, xml ) Need Help??


in reply to Re^6: Array_ref into Array_ref Help.
in thread Array_ref into Array_ref Help.

In the interest of not learning...
my $max = $#$ref_a > $#$ref_b ? $#$ref_a : $#$ref_b; my @blank_a = ("") x @$ref_a; my @blank_b = ("") x @$ref_b; my @result = map { [ $ref_a->[$_] ? @{$ref_a->[$_]} : @blank_a, $ref_b->[$_] ? @{$ref_b->[$_]} : @blank_b ] } 0..$max;
By the way, anyone have a prettier way to do this?

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://759391]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (5)
As of 2024-03-28 12:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found