perl数据结构输出 Data::Dumper

</pre><pre name="code" class="sql">oaapp01:/root/test# cat a1.pl 
use Data::Dumper;
%hash=(a=>1,b=>2,c=>3);  
$refhash=\%hash;  
print %$refhash;  
print "
"; 
print "dump 数据结构
";
print Dumper(%hash);
oaapp01:/root/test# perl a1.pl 
c3a1b2
dump 数据结构
$VAR1 = 'c';
$VAR2 = 3;
$VAR3 = 'a';
$VAR4 = 1;
$VAR5 = 'b';
$VAR6 = 2;


原文地址:https://www.cnblogs.com/hzcya1995/p/13351351.html