Java Simple programme using to do some Multiplication. In this example we are going to use java.util.Scanner to take inputs and then multiply them to get result.
/*
* Java Programe to do
* simple Multiplication
*/
import java.util.Scanner;
class Multi{
public static void main(String []args){
float x,y,product;
Scanner in=new Scanner(System.in);
System.out.println(“Enter No. one”);
x=in.nextFloat();
System.out.println(“Enter No. two”);
y=in.nextFloat();
product=x*y;
System.out.println(“Product = ” +product);
}
}