We haven’t used
delete for a while, so let’s review them with a short program. While we’re at it, let’s look at a new storage class: the static class member. The vehicle will be a
StringBad class, later to be superseded by the slightly more able
String class. (You’ve already seen the standard C++
string class, and you’ll learn more about it in Chapter 16, “The
string Class and the Standard Template Library.” Meanwhile, the humble
String classes in this chapter provide some insight into what underlies such a class. A lot of programming techniques go into providing such a friendly interface.)
String class objects will hold a pointer to a string and a value representing ...