java数据结构 大水平 课程设计 源代码(非数据库).docVIP

  • 17
  • 0
  • 约1.43万字
  • 约 16页
  • 2016-12-31 发布于贵州
  • 举报

java数据结构 大水平 课程设计 源代码(非数据库).doc

java数据结构 大水平 课程设计 源代码(非数据库)

第一个 LinList public class LinList implements List { Node head; Node current; int size; LinList(){ head = current = new Node(null); } public void index(int i) throws Exception{ if(i -1 || i size - 1){ throw new Exception(参数错误!); } if(i == -1) {current=head;return;} current = head.next; int j = 0; while((current != null) j i){ current=current.next; j ++; } } public void insert(int i,String obj) throws Exception{ if(i 0 || i size){ throw new Exception(参数错误!); } index(i - 1); current.setNext(new Node(obj,current.next)); size ++; } public

文档评论(0)

1亿VIP精品文档

相关文档