use Data::Dumper; my ($a,$b,@a); ($a,$b) = split / /, "a "; print Dumper $a,$b; ($a,$b) = @a = split / /, "a "; print Dumper $a,$b;