my $foo = 'abc this cba'; my $bar = 'ijk this kji'; ($foo = $bar) =~ s/this/that/; print "foo = $foo, bar = $bar\n";