Help for this page

Select Code to Download


  1. or download this
    use strict;
    use warnings;
    
    my @array=({key1=>1,key2=>2},{key1=>1,key2=>3},{key1=>1,key2=>5});
    print "Yes!\n" unless grep { $_->{key1} != 1 } @array;
    
  2. or download this
    #!/usr/bin/perl
    use strict;
    ...
    
    my @array=({key1=>1,key2=>2},{key1=>1,key2=>3},{key1=>1,key2=>5});
    print "Yes!\n" unless first { $_->{key1} != 1 } @array;