#include "StackType.h"
#include <iostream>
#include <string>
#include <cstddef>
using namespace std;

struct RecType {
  string name;
  string major;
  int hours;
};

int main()
{
  StackType<string> a; // stack of strings

  a.push("C++");
  a.push("Java");
  a.push("Visual Basic");
  a.push("COBOL");

  while(a.IsEmpty() == false)
    cout << a.pop() << endl;

  RecType x, y, temp;
  x.name = "John Doe";
  x.major = "CS";
  x.hours = 50;
  y.name = "Jane Doe";
  y.major = "IS";
  y.hours = 60;

  StackType<RecType> b; // stack of records

  b.push(x);
  b.push(y);

  while(!b.IsEmpty()) {
    temp = b.pop();
    cout << temp.name << " " << temp.major << " " << temp.hours << endl;
  }

  return 0;
}

