1.4 Multiplication

Question


Write a program which accept two numbers, perform Multiplication and print their Result.

Solution


class Multiplication
    {
        static void Main(string[] args)
        {
            int a, b, c;                               //initialization
            Console.Write(“Enter first number : “);
            a = Convert.ToInt16(Console.ReadLine());
            Console.Write(“Enter second number : “);
            b = Convert.ToInt16(Console.ReadLine());
            c = a * b;                                //calculation
            Console.WriteLine(“Multiplication = “ + c);
        }
    }

 Previous                                                Home                                                   Next


Output

Multiplication