日期:2014-05-20 浏览次数:20609 次
"Java"public class StringStack() { private LinkedList<String> linklist; public StringStack() { linlist=new LinkList<String>(); } public void push(String name) { linklist.addFirst(); } public String top() { return linklist.getFirst(); } public String pop() { return lijnklist.removeFirst(); } public boolean isEmpty() { return linklist.isEmpty(); } }