C#双向链表double linkedlist
using System;
namespace DLL
{
class Node
{
public Node prev;
public Node next;
public object obj;
}
public class doubleLinkedList
{
private Node head;
private Node tail;
private int count;
public void AddLast(object obj)
{
if (head == null)
{
head = new Node();
head.obj = obj;
head.next = null;
tail = head;
}
else
{
Node toAdd = new Node();
toAdd.obj = obj;
tail.next = toAdd;
toAdd.prev = tail;
tail = toAdd;
}
count++;
}
private