Re: How Do I initialize an empty array

2003-10-29 Thread Tore Aursand
On Tue, 28 Oct 2003 11:53:44 -0700, Wiggins d Anconia wrote: > or if you know the length of the array ahead of time: > > my @rows = ('','',''); I prefer the following instead: my @rows = ('') x 3; Easier to read...? -- Tore Aursand <[EMAIL PROTECTED]> -- To unsubscribe, e-mail: [EMAIL P

Re: How Do I initialize an empty array

2003-10-28 Thread Rob Dixon
<[EMAIL PROTECTED]> wrote: > > How Do I initialize an empty array so thtat I don't get an unitiialized > error? > > ... > my @rows; > > I thought I could do something like @rows = new (); but it's not working. You don't. my @rows; declares an array, which is initially empty. If you put somethi

Re: How Do I initialize an empty array

2003-10-28 Thread perl
thanks. it works. @rows=(); -- > > >> How Do I initialize an empty array so thtat I don't get an unitiialized >> error? >> >> ... >> my @rows; >> >> I thought I could do something like @rows = new (); but it's not >> working. >> > > Drop the 'new': > > my @rows = (); > > http://danconia.org >

Re: How Do I initialize an empty array

2003-10-28 Thread Wiggins d Anconia
> > > > How Do I initialize an empty array so thtat I don't get an unitiialized > > error? > > > > ... > > my @rows; > > > > I thought I could do something like @rows = new (); but it's not working. > > > > Drop the 'new': > > my @rows = (); > Are you sure you are getting the warning on

Re: How Do I initialize an empty array

2003-10-28 Thread Wiggins d Anconia
> How Do I initialize an empty array so thtat I don't get an unitiialized > error? > > ... > my @rows; > > I thought I could do something like @rows = new (); but it's not working. > Drop the 'new': my @rows = (); http://danconia.org -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additi