#!/usr/bin/perl use strict; my @array = ({key1=>1, key2=>2, key3=>3}, {key1=>1, key2=>2, key3=>3}, + {key1=>1, key2=>2, key3=>3} ); my $amount = scalar(@array); if (!$array[0 .. $amount]->{key1}) { print "no\n" }
In reply to Re^2: Checking if all the key values are same in an Array
by jbrugger
in thread Checking if all the key values are same in an Array
by perl_devel
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |