Computer Science, asked by kanupriya163, 3 months ago

write a class to input two integer and print the following using mathematical methods-
1) smallest of two numbers
2) square of two numbers
3) cube of second number

no spam otherwise will be reported​. you have to write a Java program which should be suitable for class 9 student. if you don't know, don't reply​

Answers

Answered by keyboardavro
1

Answer:

Explanation:

// Java program to demonstrate the  

// use of min() function  

// two double data-type numbers are passed as argument  

public class Gfg {  

 

   public static void main(String args[])  

   {  

       double a = 12.123;  

       double b = 12.456;  

 

       // prints the minimum of two numbers  

       System.out.println(Math.min(a, b));  

   }  

}

Similar questions