1. Write a method which returns the volume of a cube, given the length of one side. A sample call is:
double vol = cubeVolume(1.2);
2. Write a method which returns the area of a circle, given its radius as a parameter. A sample call is:
double a = areaCircle(1.25);
The area of a circle is given by the formula Math.PI * r * r. Though we could use a number such as 3.14, a more accurate value is provided by Math.PI.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here