Create and Delete
Let's start things off by learning how to create and destroy strings.
C++ offers many methods to create strings from C or C++ strings. Under the hood, there is always a C string involved for creating a C++string. That changes with C++14, because the new C++ standard supports C++ string literals: std::string str{"string"s}
. With the suffix s,the C string literal "string literal"
becomes a C++string literal: ...