Created
December 8, 2015 20:06
-
-
Save AnnaBoro/33158126e390558d6f63 to your computer and use it in GitHub Desktop.
MyList1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package lesson7.mylist; | |
public class Node { | |
private Object o; | |
private Node node; | |
public Node() { | |
} | |
public Object getO() { | |
return o; | |
} | |
public void setO(Object o) { | |
this.o = o; | |
} | |
public Node getNode() { | |
return node; | |
} | |
public void setNode(Node node) { | |
this.node = node; | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package lesson7.mylist; | |
public class SimpleLinkedList { | |
private Node root; | |
private int size; | |
public SimpleLinkedList() { | |
} | |
public void addFirst(Object o) { | |
} | |
public void addLast(Object o) { | |
} | |
public void addAfter(Object o, Object n) { | |
} | |
public Node getRoot() { | |
return root; | |
} | |
public void setRoot(Node root) { | |
this.root = root; | |
} | |
public int getSize() { | |
return size; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment