perl_devel has asked for the wisdom of the Perl Monks concerning the following question:
@array=({key1=>1,key2=>2},{key1=>1,key2=>3},{key1=>1,key2=>5});
is there a simple method to check if all the key1 are 1 in the above array other than looping the arrayjanitored by ybiC: Balanced <code> tags around snippet, as per Monastery convention
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Checking if all the key values are same in an Array
by deibyz (Hermit) on Apr 26, 2005 at 11:32 UTC | |
by holli (Abbot) on Apr 26, 2005 at 11:34 UTC | |
by ysth (Canon) on Apr 28, 2005 at 06:06 UTC | |
Re: Checking if all the key values are same in an Array
by salva (Canon) on Apr 26, 2005 at 11:35 UTC | |
Re: Checking if all the key values are same in an Array
by holli (Abbot) on Apr 26, 2005 at 11:32 UTC | |
by jbrugger (Parson) on Apr 26, 2005 at 13:04 UTC | |
by holli (Abbot) on Apr 26, 2005 at 13:16 UTC |