提交 3d198c09 编写于 作者: S shuang.kou

Update Java程序设计题.md

上级 2ceb03b1
......@@ -73,7 +73,7 @@ public class MyStack {
//TODO:返回栈顶元素并出栈
private int pop() {
if (count == -1)
if (count == 0)
throw new IllegalArgumentException("Stack is empty.");
count--;
return storage[count];
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册