Computer Science, asked by Abhishekhero1, 1 year ago

write a program in Java to assign an integer value 33 and fractional value 12.5. print the cube of integer and square of fractional value

Answers

Answered by Vintage
19
int a=33;
double d=12.5;
System.out.println(a*a*a);
System.out.println(d*d);
Answered by akshat127
10
import java. io. *;
public class cube

{
BufferedReader in=new BufferedReader(new InputStreamReader(System. in) )
{
int c;
double b;
System.out.println("The cube of 33 is"+ (c*c*c) );
System.out.println("Square is"+(Math. pow(12.5,2) );
}
}
Similar questions