Example #1
0
        public override bool Equals(Object obj)
        {
            BitArray64 num = obj as BitArray64;

            if (num == null)
            {
                return(false);
            }
            else if (this.Number != num.Number)
            {
                return(false);
            }

            return(true);
        }
Example #2
0
        static void Main(string[] args)
        {
            BitArray64 number    = new BitArray64(50);
            BitArray64 numberTwo = new BitArray64(2000);

            // foreach all bits in number
            foreach (var bits in number)
            {
                Console.Write(bits);
            }
            Console.WriteLine();

            Console.WriteLine(number.Equals(numberTwo));
            Console.WriteLine(number == numberTwo);
        }
Example #3
0
 public static bool operator !=(BitArray64 num, BitArray64 num2)
 {
     return(!(BitArray64.Equals(num, num2)));
 }