jeffp@hut [3:04pm] ~ #103> perl -MBenchmark timethese(1_000_000, { 'swap' => q{ ($a,$b) = ($b,$a) }, 'three' => q{ { my $c = $a; $a = $b; $b = $c } }, }); Benchmark: timing 1000000 iterations of swap, three... swap: 17 wallclock secs ( 5.04 usr + 0.00 sys = 5.04 CPU) @ 198449.61/s (n=1000000) three: 29 wallclock secs ( 5.96 usr + 0.01 sys = 5.97 CPU) @ 167539.27/s (n=1000000)