Exemple #1
0
 private static void callStaticMethods()
 {
     Console.WriteLine("The Added value is " + MathComponent.AddFunc(123, 23));
     Console.WriteLine("The Subtracted value is " + MathComponent.SubFunc(123, 23));
     Console.WriteLine("The Multiplied value is " + MathComponent.MulFunc(123, 23));
     Console.WriteLine("The Divided value is {0:#.##}", MathComponent.DivFunc(12876873, 23));
 }
Exemple #2
0
        static void Main(string[] args)
        {
            MathComponent com = new MathComponent();

            Console.WriteLine(com.AddFunc(123, 324));
            Console.WriteLine(com.SubFunc(123, 324));
            Console.WriteLine(com.MulFunc(123, 324));
            Console.WriteLine(com.DivFunc(123, 324));
        }