import java.util.*;

public class teststack {
	
	public static void main(String[] args) {
		
		Scanner stdin = new Scanner(System.in);
		stack mystack = new stack();
		
		mystack.push(new Car("Kurt"));
		mystack.push(new CD("Logan", "SoundsOfTheRAM", 81253, 19.95));
		System.out.println(mystack.pop());
		mystack.push("THISISASTRING.");
		System.out.println(mystack.pop());
		System.out.println(mystack.pop());
		
		/*
		while (true) {
			
			System.out.println("Would you like to (1)push, (2)pop, (3)quit");
			int ans = stdin.nextInt();
			
			if (ans == 1) {
				System.out.println("enter string to push onto stack.");
				boolean result = mystack.push(stdin.next());
				if (!result)
					System.out.println("Your stack was full, nothing was pushed.");
			}
			else if (ans == 2) {
			
				if (!mystack.empty())
					System.out.println("Popped "+mystack.pop()+" from the stack.");
				else
					System.out.println("empty stack");
			}
			else
				break;
		}
		*/
	}
}