顺序表类实.docVIP

  • 2
  • 0
  • 约4.67万字
  • 约 6页
  • 2016-12-25 发布于河南
  • 举报
#include iostream #include cstdlib usingnamespacestd; classNode { public: intdata; Node *next; public: Node() { next=NULL; } Node(inta) { data=a; next=NULL; } }; classList { public: Node *head; public: List() { head=newNode(); } ~List() { Node *p=head-next; while(p) { Node *s=p; p=s-next; free(s); } free(head); } voidinitial() { Node *zhen; zhen=head; inti; cini; for(int

文档评论(0)

1亿VIP精品文档

相关文档