return two hashes for sub
http://www.perlmonks.org/?node_id=647264
You'll need to return references to your hashes from the sub, as in:
return(\%test1, \%test2);
In the caller, if you must, you can dereference the hashrefs by:
my ($test1,$test2) = &testsub;
my %test1 = %$test1;
my %test2 = %$test2;
好的心态+正确的方法
浙公网安备 33010602011771号