public override bool Equals(object obj) { BitArray64 otherNumber = obj as BitArray64; if (this.DecimalNumber == otherNumber.DecimalNumber) { return(true); } return(false); }
static void Main() { BitArray64 bits = new BitArray64(4611703610613764096, true); BitArray64 bits2 = new BitArray64(4611703610613764096, false); BitArray64 testBits = new BitArray64(111); Console.WriteLine(bits); Console.WriteLine(bits2); Console.WriteLine(bits.Equals(bits2)); Console.WriteLine(testBits); testBits[0] = 1; Console.WriteLine(testBits); testBits[2] = 0; Console.WriteLine(testBits); }
public static bool operator !=(BitArray64 first, BitArray64 second) { return(!BitArray64.Equals(first, second)); }