Advertisement
KShah

Untitled

Nov 12th, 2021
808
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.25 KB | None | 0 0
  1. String& operator+=(const String& s) {
  2.         for (size_t i = 0; i < s.sz; ++i) {
  3.             push_back(s[i]);
  4.         }
  5.         return *this;
  6.     }
  7.    
  8.     String& operator+=(const char c) {
  9.         push_back(c);
  10.         return *this;
  11.     }
  12.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement