//******************************************************************* // // Program: Testing Strings in a program // // Author: Art Miller, amiller@mta.ca // // Description: CS 1711 Lab 3: // // A program to demonstrate the use of string input // in C++. (uses tstring.h) // // Date: October 12, 1999 // // Course Information: CS 1711 // // Filename: teststrg.cpp // //********************************************************************* // #include #include "tstring.h" void main () { String string1; String string2; String concat; String reversal; cout << "String input demo" << endl; cout << "--------------------------------------------" << endl; cout << "Enter several strings (sep'd by whitespace)" << endl; cin >> string1; cin >> string2; concat = string1 + string2; reversal = string2 + string1; cout << endl; cout << "string1 is :" << string1 << endl; cout << "string2 is :" << string2 << endl; cout << "string 1 + string 2 is :" << concat << endl; cout << "reversal is :" << reversal << endl; }