Guest User

Untitled

a guest
Oct 17th, 2018
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.22 KB | None | 0 0
  1. string myString = 'Hello';
  2. string shifted = myString + 2;
  3. cout << shifted << endl;
  4.  
  5. std::string myString = 'Hello';
  6. std::string shifted;
  7.  
  8. for (auto const &ch : myString)
  9. shifted += ch + 2;
  10.  
  11. std::cout << shifted << '';
Add Comment
Please, Sign In to add comment