=>
[oracle@dwh1 perl]$ cat a1.pl
my %a = (
a=>100,
b=>200,
c=>300);
print "$a{a}
";
[oracle@dwh1 perl]$ perl a1.pl
100
->
[oracle@dwh1 perl]$ cat a1.pl
my %a = (
a=>100,
b=>200,
c=>300);
print "$a{a}
";
print "$a->{'a'}
";
[oracle@dwh1 perl]$ perl a1.pl
100
[oracle@dwh1 perl]$
->
1.第一种用法:
解引用
2.调用类或者对象的方法