// Dave Goldsmith // Redwood High School // C++ Computer Programming // October 24, 1999 // APvector4.cpp /* This program demonstrates how a specific character in an element of an apvector of apstrings can be accessed. This is essentially the same way individual characters are accessed from apstrings. */ #include // Required for 'cin' and 'cout' #include // Required for 'apstring' #include // Required for 'apstring' #include // Required for 'apvector' int main() { apvector word(4, ""); // Array of 4 apstrings, all empty word[2] = "aardvark"; // Set 3rd element cout << word[2] << endl; // Show 3rd element cout << word[2][4] << endl; // Show 5th character of 3rd element return 0; }