Exemplo n.º 1
0
 public int IndexOf(Product pdt)
 {
     int ret = -1;
     bool found = false;
     int c = 0;
     while (!found && c < Count) {
         if (pdt.Equals(Products[c++])) {
             found = true;
             ret = c-1;
         }
     }
     return ret;
 }