public class LLStackTest
{
public static void main(String args[])
{
LList list = new LList();
Stack s = list;
s.push(new Integer(3));
s.push(new Integer(4));
s.push(new Integer(5));
if (s.height() != 3)
{
System.out.println("incorrect height");
}
else
{
System.out.println("correct: height is 3");
}
Enumeration e = list.elements();
while (e.hasMoreElements())
{
System.out.println(e.nextElement());
}
int a = ((Integer) s.pop()).intValue();