In the following C++ code, there should be three heap allocations as in the swap() function one temporary string object is also created. Why there are only two
swap()