Ejemplo n.º 1
0
        public static void RemoveLongestCall()
        {
            List <Call> longestCall = generateCalls.OrderBy(x => x.Duration).ToList(); //getting the longest call from the list of calls

            longestCall.RemoveAt(longestCall.Count - 1);
            decimal price = GSM.CalculateTotalCallPrice(longestCall, 0.37M); //using method of the GSM class

            Console.WriteLine("Total price without longest call: {0:F2}", price);
        }
Ejemplo n.º 2
0
        public static void CalculateAndPrintTestcallsPrice()
        {
            decimal price = GSM.CalculateTotalCallPrice(generateCalls, 0.37M); //using method of the GSM class

            Console.WriteLine("Total price of test calls: {0:F2}", price);
        }