Example #1
0
        static void Main(string[] args)
        {
            //Начало цикла
            do
            {
                Console.WriteLine("START");

                BigInteger expectedResult2 = BigInteger.Pow(10, 1);
                BigInteger expectedResult1 = BigInteger.Pow(9, 1);

                Console.WriteLine(BigInteger.Compare(expectedResult1, expectedResult1));

                int[] input = GetInput();
                var   a     = LongArithmetic.Compare(
                    LongArithmetic.Pow(input[0], input[1]),
                    LongArithmetic.Pow(input[2], input[3])
                    );
                Console.Write("Число: ");
                foreach (var m in a[0])
                {
                    Console.Write(m);
                }
                Console.Write("\nБольше на ");
                foreach (var m in a[1])
                {
                    Console.Write(m);
                }

                Console.WriteLine("\n#Enter any character to complete");
            } while (Console.ReadLine().Length != 1);
        }
        public void TestCompare()
        {
            int expectedCompare = BigInteger.Compare(expectedResult1, expectedResult2);
            int actualCompare   = LongArithmetic.Compare(actualResult1, actualResult2)[2][0];

            Assert.AreEqual(expectedCompare, actualCompare);
        }