public ParentNode()
 {
     cn = new ChildNode[1000];
     for (int i = 0; i < 1000; i++)
     {
         cn[i] = new ChildNode();
         cn[i].namakota = "";
         cn[i].jarak = -1;
     }
 }
Esempio n. 2
0
 public ParentNode()
 {
     cn = new ChildNode[1000];
     for (int i = 0; i < 1000; i++)
     {
         cn[i]          = new ChildNode();
         cn[i].namakota = "";
         cn[i].jarak    = -1;
     }
 }
 public void addchild(string namakotanya,int jaraknya)
 {
     for (int i = 0; i < 1000; i++)
     {
         if(cn[i].namakota.Equals(""))
         {
             cn[i] = new ChildNode();
             cn[i].namakota = namakotanya;
             cn[i].jarak = jaraknya;
             break;
         }
     }
 }
Esempio n. 4
0
 public void addchild(string namakotanya, int jaraknya)
 {
     for (int i = 0; i < 1000; i++)
     {
         if (cn[i].namakota.Equals(""))
         {
             cn[i]          = new ChildNode();
             cn[i].namakota = namakotanya;
             cn[i].jarak    = jaraknya;
             break;
         }
     }
 }