Remember: A string
is a sequence of multiple characters, such as words, sentences, or
addresses. They are referred to as alphanumerics
(alphabet characters and/or numbers). As we have already discovered, there is no built-in string data type
in standard C++. We created "strings" by using an array
of characters, such as
char name[ ] =
"Alexis";
We quickly discovered that these "strings" were
difficult to manipulate - such as the difficulties associated with assigning new values.
The College Board has allowed for the inclusion of the
APSTRING class to allow for easier manipulation of
"strings". There are two necessary components to using the
APSTRING class:
"apstring.h" |
- library (commented) header file for
new manipulation functions |
"apstring.cpp" |
- implementation header file. It
uses #include <string.h>, #include <assert.h>, and
#include "apstring.h" |
|