コード例 #1
0
        static void Main(string[] args)
        {
            var list = new LinkedListofNode();

            list.Add(5);
            list.Add(3);
            list.Add(4);
            list.Add(5);
            list.Add(6);
            list.Add(9);
            foreach (var item in list)
            {
                Console.WriteLine(item.data);
            }
        }
コード例 #2
0
 /// <summary>
 /// ctor thet takes the list that must be enumerated as a parametr
 /// </summary>
 /// <param name="list"></param>
 public LinkedListEnumerator(LinkedListofNode list)
 {
     this.lst = list;
 }