// File: bstmain.C
//
// Testing the BStringStack class

#include <iostream.h>
#include <iomanip.h>
#include <stdlib.h>
#include <string.h>
#include "bstrstack.h"

main() {
   BStringStack S ;
   BString bs ;
   int length ;

   S.push("Space") ;
   S.push("the") ;
   S.push("final") ;
   S.push("frontier") ;
   S.push("These") ;
   S.push("are") ;
   S.push("the") ;
   S.push("voyages") ;
   S.push("of") ;
   S.push("the") ;
   S.push("starship") ;
   S.push("Enterprise") ;
   S.print() ;
   cout << endl ;
   length = S.length() ;
   cout << "length = " << length << endl ;
   cout << endl ;

   cout << "Remove: " << S.pop() << endl ;
   cout << "Remove: " << S.pop() << endl ;
   cout << "Remove: " << S.pop() << endl ;
   cout << "Remove: " << S.pop() << endl ;
   cout << "Remove: " << S.pop() << endl ;
   cout << "Remove: " << S.pop() << endl ;

   S.print() ;
   length = S.length() ;
   cout << "length = " << length << endl ;
}
