循环单链表
public class Node { public Object data; public Node next; public Node(){} public Node(Object data,Node next){ this.data = data; this.next = next; } } public class CirSingleLink { private Node node = null; private int size = 0; public void init(){ node = new Node(); node.data = null; //头结点指向头结点 node.next = node; } //从尾结点进行插入 public void add(Object i){ Node newNode = new Node(i,node); if(node.next == node){ node.next = newNode; }else{ Node tmp = node; while (tmp.next != node){ tmp =tmp.next; } tmp.next = newNode; } size ++; } public void delete(Object i){ Node tmp = node; while(tmp.next !=