예제 #1
0
 public void PrintLinkedList()
 {
     LinkedList.Node n = this.head;
     while (n != null)
     {
         System.Console.WriteLine(n.data.ToString());
         n = n.next;
     }
 }
예제 #2
0
        public Node LastNode()
        {
            LinkedList.Node n = this.head;

            while (n.next != null)
            {
                n = n.next;
            }
            return(n);
        }