use strict; use Data::Compare; my $h1 = { 'recid2' => '345', 'recid1' => '123' }; my $h2 = { 'recid1' => '123', 'recid2' => '345' }; my @a1 = (1,2,3); my @a2 = (3,2,1); # simple procedural interface print 'structures of $h1 and $h2 are ', Compare($h1, $h2) ? "" : "not ", "identical.\n"; # simple procedural interface print 'structures of $a1 and $a2 are ', Compare(\@a1, \@a2) ? "" : "not ", "identical.\n";