Sunday 22 September 2013

Multiplication of two numbers.

PROGRAM CODING:

class Multiplication
{
public static void main(String args[])
{
int a=Integer.parseInt(args[0]);
int b=Integer.parseInt(args[1]);
int c;
c=a*b;
System.out.println("The Multiplication of two value is"+c);
}
}

OUTPUT:

C:\Program Files (x86)\Java\jdk1.7.0_25\bin\Lokey>javac Multiplication.java
C:\Program Files (x86)\Java\jdk1.7.0_25\bin\Lokey>jfava Multiplication 10 6
The Multiplication of two value is 60

No comments:

Post a Comment