Exemple #1
0
 public void AddToEnd(int x, int y)
 {
     if (next == null)
     {
         next = new SnakeNode(x, y);
     }
     else
     {
         next.AddToEnd(x, y);
     }
 }
Exemple #2
0
 public void AddToEnd(int x, int y)
 {
     if (headNode == null)
     {
         headNode = new SnakeNode(x, y);
     }
     else
     {
         headNode.AddToEnd(x, y);
     }
 }