my %hash = ( 'a' => 2, 'b' => 3, 'c' => 4, ); use Data::Dumper; say Dumper(\%hash); --output:-- $VAR1 = { 'c' => 4, 'a' => 2, 'b' => 3 };