How to multiply 2 numbers in JAVA?

How to multiply 2 numbers in JAVA?



class mul
{
        public static void main(String[] args)
        {
                int a=10,b=2;
                int c;
                c=a*b;
                System.out.println("mul=" +c);
        }
}

Output:
20
How to multiply 2 numbers in JAVA? How to multiply 2 numbers in JAVA? Reviewed by Unknown on January 28, 2019 Rating: 5

No comments:

If you have any doubt or query ,comment below:

Programming copyright © 2018-19. Powered by Blogger.