in reply to De-Reference an array

I'm not sure you really want to do what you think you are doing. Your code would be much cleaner, faster, and do what you mean if you kept it all in one script and used subs, like so:

use strict; use warnings; my @array1 = ( 1 .. 3 ); my @array2 = ( 4 .. 6 ); print2arrs( \@array1, \@array2 ); sub print2arrs { my ( $ref1, $ref2 ) = @_; print @$ref1; print @$ref2; }

And if you really do need to keep them in separate files, check out require or do to avoid using the system command and firing off an entirely new perl interpreter

print pack("A25",pack("V*",map{1919242272+$_}(34481450,-49737472,6228,0,-285028276,6979,-1380265972)))

Replies are listed 'Best First'.
Re^2: De-Reference an array
by Ankit.11nov (Acolyte) on Oct 12, 2009 at 06:28 UTC
    Hi Steve, Thanks for the piece of code.

    What I am working upon: 1) Parsing ~100 of XML files 2) The information which is extracted is kept in an different arrays 3) Info available in the arrays is entered into an excel sheet.

    Thats what I was exploring with this small piece of code.