@Test public void testPeek() { ss.push("howdy mundo"); assertEquals("howdy mundo", ss.peek()); }
@Override public T peek() { if (depth == 0) { return null; } return stack[depth-1]; }
MyStack implements SimpleStack<T> { @Override public T peek() { if (depth == 0) { return null; } return stack[depth-1]; } }
MyStack implements SimpleStack<T> { @Override public T peek() { if (depth == 0) { return null; } return stack[depth-1]; } MyStack();  MyStack(int howBig); }
MyStack implements SimpleStack<T> { @Override public T peek() { if (depth == 0) { return null; } return stack[depth-1]; } MyStack();  MyStack(int howBig); @Override boolean empty(); @Override void push(T obj); @Override T pop(); @Override T peek(); boolean hasNext(); boolean hasRoom(); int getStackDepth(); }
MyStack implements SimpleStack<T> { @Override public T peek() { if (depth == 0) { return null; } return stack[depth-1]; } MyStack();  MyStack(int howBig); @Override boolean empty(); @Override void push(T obj); @Override T pop(); @Override T peek(); boolean hasNext(); boolean hasRoom(); int getStackDepth(); static final int DEFAULT_INITIAL; }