Re: reference of an array into an array

2010-11-04 Thread Christian
the final loop values. > One solution: declare @mytemp within -- rather than outside -- > the loop. This allocates new memory for @mytemp during > each loop iteration to prevent overwriting. > > while(<$myfile>) >{ >($a, $b $c ) = getparameter(); >my @mytemp = (

Re: reference of an array into an array

2010-11-04 Thread Dr.Ruud
On 2010-11-04 10:16, Christian Stalp wrote: Hello together, I try to write some arrays into arrays using references. my ($a, $b, $c, @mytemp, $myref, @my_globael_array) while(<$myfile>) { ($a, $b $c ) = getparameter(); @mytemp = ($a, $b, $c); $myref = \...@mytemp; push(@my_glob

Re: reference of an array into an array

2010-11-04 Thread C.DeRykus
On Nov 4, 2:16 am, christian1...@gmx.net ("Christian Stalp") wrote: > Hello together, > I try to write some arrays into arrays using references. > > my ($a, $b, $c, @mytemp, $myref, @my_globael_array) > > while(<$myfile>) > { >    ($a, $b $c ) = getparameter(); >   �...@mytemp = ($a, $b, $c); >    

Re: reference of an array into an array

2010-11-04 Thread Robert Wohlfarth
On Thu, Nov 4, 2010 at 4:16 AM, Christian Stalp wrote: > Hello together, > I try to write some arrays into arrays using references. > > my ($a, $b, $c, @mytemp, $myref, @my_globael_array) > > while(<$myfile>) > { > ($a, $b $c ) = getparameter(); > @mytemp = ($a, $b, $c); > $myref = \...@myte

Re: reference of an array into an array

2010-11-04 Thread Shlomi Fish
Hi Christian. On Thursday 04 November 2010 11:16:46 Christian Stalp wrote: > Hello together, > I try to write some arrays into arrays using references. > > my ($a, $b, $c, @mytemp, $myref, @my_globael_array) Your code won't compile - you've mis-spelt "global" and you're missing a trailing semic

reference of an array into an array

2010-11-04 Thread Christian Stalp
Hello together, I try to write some arrays into arrays using references. my ($a, $b, $c, @mytemp, $myref, @my_globael_array) while(<$myfile>) { ($a, $b $c ) = getparameter(); @mytemp = ($a, $b, $c); $myref = \...@mytemp; push(@my_global_array, $myref); } But if I dismantle @my_globa