Example #1
0
        public void ConvertBest5ToLinkedList(int[] best5)
        {
            foreach (int t in best5)
            {
                if (t != 1000)
                {
                    TimeNode tnode = new TimeNode(t);

                    if (First != null)
                    {
                        //there are 1 or more items already in the linked list
                        Last.Next = tnode;
                        Last      = tnode;
                    }
                    else
                    {// there are no items in the linked list
                        First = tnode;
                        Last  = First;
                    }
                }
            }
        }
Example #2
0
 public LinkedTimeList()
 {
     First = null;
     Last  = null;
 }
Example #3
0
 public TimeNode(int time)
 {
     Time = time;
     Next = null;
 }