$str = 'one two three'; ($x,$y,$z) = split(' ',$str); print "my three variables are $x, $y and $z";