print $condition ? ($a=~s/foo/bar/, $a) : $a;