[question] : array

2012-04-01 Thread Eko Budiharto
hi list, I would like to ask about 2 dimensional array my code: my $ref = $sth->fetchall_arrayref(); foreach my $row (@$ref) { ( $KODE_UNIT, $KODE_BAGIAN, $NIK, $TANGGAL ) = @$row; @row = @$row; push(@array_2d, @row ); print ""; print "width=>@array_2d[0][0]@array_2d[0][1]@array

Re: [question] array

2012-03-30 Thread Dr.Ruud
On 2012-03-30 12:33, Eko Budiharto wrote: I would like to ask about 2 dimensional array Each element of a Perl array is a scalar. my @colors = ( "red", "white", "blue" ); which can also be written as: my @colors = qw( red white blue ); and can be used as: print "ok" if $colors[ 2

RE: [question] array

2012-03-30 Thread Ken Slater
> -Original Message- > From: Eko Budiharto [mailto:eko.budiha...@gmail.com] > Sent: Friday, March 30, 2012 6:33 AM > To: beginners@perl.org > Subject: [question] array > > hi list, > I would like to ask about 2 dimensional array > > my code: >

[question] array

2012-03-30 Thread Eko Budiharto
hi list, I would like to ask about 2 dimensional array my code: my $ref = $sth->fetchall_arrayref(); foreach my $row (@$ref) { ( $KODE_UNIT, $KODE_BAGIAN, $NIK, $TANGGAL ) = @$row; @row = @$row; push(@array_2d, @row ); print ""; print "width=>@array_2d[0][0]@array_2d[0][1]@array

RE: Question: Array of Hashes

2005-03-31 Thread Olivier, Wim W
Thanks Offer! It's working! Wim -Original Message- From: Offer Kaye [mailto:[EMAIL PROTECTED] Sent: 31 March 2005 02:55 PM To: Perl Beginners Subject: Re: Question: Array of Hashes On Thu, 31 Mar 2005 14:40:47 +0200, Olivier, Wim W wrote: > Hi all, > > I have the

Re: Question: Array of Hashes

2005-03-31 Thread Offer Kaye
On Thu, 31 Mar 2005 14:40:47 +0200, Olivier, Wim W wrote: > Hi all, > > I have the following code below which I need to modify a bit. > > The script currently lists the key/value pairs for all processes in the > system. > What I need to achieve is for it to only list the key/value pairs for > pro

Question: Array of Hashes

2005-03-31 Thread Olivier, Wim W
Hi all, I have the following code below which I need to modify a bit. The script currently lists the key/value pairs for all processes in the system. What I need to achieve is for it to only list the key/value pairs for processes of which the "Description" key is of a certain ASCII value, say "an

Re: WWW::Mechanize question / array values

2004-05-12 Thread JupiterHost.Net
Next and hopefully last question for now on a more general subject: Why do array members take the form of 'ARRAY(0x90df74)' rather than the actual content fed to an array or variable? Whatever variable looks like that when printed if an array reference. for(@links) { print @{$_}; } see perldoc p

Re: WWW::Mechanize question / array values

2004-05-12 Thread Ben Miller
On 5/12/04 1:26 PM, Paul Johnson wrote: > On Wed, May 12, 2004 at 12:59:44PM -0500, Ben Miller wrote: > >> my @links = $mech->find_all_links(tag = "a", text_regex => qr/\bWORD\b/i ); > > ... tag => "a", ... > > I suspect. Thank you to Paul and to Lee for their quick and efficient answer. That