0
How can i display the volume of a square as 1m^3 instead off 100000 cm^3?
3 Answers
+ 1
You mean instead of 10000 cm^3? Just divide the result by 10000.
0
yeah but how do i get the result output in m^3 instead off cm^3?
0
public class Bsp01 {
public static void main(String []args){
double H, L, B, V;
System.out.println ();
System. out.println ("H [cm]:");
H = SavitchIn.readLineDouble ();
System.out.println("B [cm]:");
B = SavitchIn.readLineDouble();
System.out.println("L [cm]:");
L = SavitchIn.readLineDouble();
V = H * B * L;
System.out.println(" V = " + V);
System.out.println();
}
}
thats what i have so far! is ot correct?