yan*_*s96 1 c++ string string-concatenation
可能重复:
如何在一行上连接多个C++字符串?
我该怎么做:
string test1 = "Hello ";
string test2 = "World!";
Run Code Online (Sandbox Code Playgroud)
并将它们连接起来制作一个字符串?
怎么样
string test3 = test1 + test2;
Run Code Online (Sandbox Code Playgroud)
或者可能
test1.append(test2);
Run Code Online (Sandbox Code Playgroud)