protected void InsertData(Day15_LinkedList list) { foreach (int item in Data) { Head = list.Insert(Head, item); } }
public void Test() { Day15_LinkedList linkedList = new Day15_LinkedList(); InsertData(linkedList); Console.WriteLine("Day 15: Linked List: "); Console.WriteLine("Input: "); Console.WriteLine("{0}", PrintList <int>(Data)); Console.WriteLine("Output: "); Console.WriteLine("{0}", linkedList.Display(Head)); Console.WriteLine(" "); }