JAVA 单向链表 双向链表

来源:百度知道 编辑:UC知道 时间:2024/05/26 21:42:29
哪位大侠帮我解释一下,这两个的意思。有什么不同?越精简越好。长篇大论我看不明白了。

还有里面的Head、Tail、Length,Pointer都是怎么用的。谢过,谢过!
里面的Head、Tail、Length,Pointer怎么用呢? 着急,在线等。。谁有这方面的网页教程,我慢慢读也行。

看看
http://www.baidu.com/s?bs=v&f=8&wd=JAVA+%B5%A5%CF%F2%C1%B4%B1%ED+%CB%AB%CF%F2%C1%B4%B1%ED

//双向链表的简单表达

public class Mulit {

private class Node
{
private String data;
private Node upNode;
private Node downNode;
public Node()
{
data=null;
upNode=null;
downNode=null;

}
public Node(String newData,Node newDownNode)
{
data=newData;
downNode=newDownNode;
// upNode=newDownNode;
}

}
Node head;
public Mulit()
{
head=null;

}
public void add(String newData)
{
Node lastNode=head;

if(head==null)
head=new Node(newData,head);
else<