Advertisement
Guest User

Untitled

a guest
Feb 19th, 2019
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. #include <iostream>
  2. #include <algorithm>
  3. #include <vector>
  4. #include <iomanip>
  5. #include <cmath>
  6. #include <string>
  7. #include <stack>
  8.  
  9. using namespace std;
  10.  
  11. int main() {
  12.  
  13. string a = "abc";
  14. string b = "abcd";
  15.  
  16. string *numa = &a;
  17.  
  18. string *numb = &b;
  19.  
  20. string *temp = new string();
  21.  
  22. *temp = a;
  23. a = *numb;
  24. b = *temp;
  25.  
  26. return 0;
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement