Ejemplo n.º 1
0
 public bool Equals(Combination other)
 {
     if (ReferenceEquals(null, other)) return false;
     if (ReferenceEquals(this, other)) return true;
        return  (GetHashCode() == other.GetHashCode() &&
      values.All(i => values.Count(i1 => i==i1) == other.values.Count(i2 => i2==i)));
 }
Ejemplo n.º 2
0
 public Combination(Combination combination,int newValue)
 {
     var ints = new List<int>(combination.values) {newValue};
     values = ints;
 }