예제 #1
0
        static void Main(string[] args)
        {
            long time;

            Console.WriteLine(GCD.Euclid(out time, -5, 0) + "    time = " + time + " ms");
            Console.WriteLine(GCD.Euclid(out time, 78, 294, 570, 36) + "    time = " + time + " ms");

            Console.WriteLine(GCD.BinaryGCD(out time, -5, 0) + "    time = " + time + " ms");
            Console.WriteLine(GCD.BinaryGCD(out time, 78, 294, 570, 36) + "    time = " + time + " ms");
            Console.ReadKey();
        }
예제 #2
0
        public int GCDBinaryCount(params int[] nums)
        {
            double execTime = 0;

            return(GCD.BinaryGCD(out execTime, nums));
        }