第1个回答 2013-01-15
use Clone qw/clone/;
use Data::Dumper;
$center_point = {
x => undef, y => undef,
dx => undef, dy => undef,
};
$cp = clone $center_point;
$center_point -> {x} = 1; $center_point -> {y} = 2;
$cp -> {x} = "a"; $cp -> {y} = "b";
print Dumper $center_point;
print Dumper $cp;本回答被网友采纳
第2个回答 2013-01-15
$a=1.2;
$b=1.3;
$c=1.2;
$str=pack('ffff',$a,$b,$c,$d);
@d=unpack('ffff',$str);
print "@d";