变量互换


##方法1
$a= 3;
$b=4;
$a.=$b;
$b = substr($a, 0,strlen($a)-strlen($b));
$a = substr($a, strlen($b));
echo $a,'-',$b;

##方法2
$a= 3;
$b=4;
list($a,$b) = [$b,$a];
echo $a,'-',$b;