Exercise 3: A. Write static methods: • public static double sphereVolume(double r) :r3 • public static double sphereSurface(double r) : 47tr? • public static double coneVolume(double r, double h): –...


Exercise 3:<br>A. Write static methods:<br>• public static double sphereVolume(double r) :r3<br>• public static double sphereSurface(double r) : 47tr?<br>• public static double coneVolume(double r, double h): – thr²<br>public static double coneSurface(double r, double h) :7r(h +r)<br>that compute the volume and surface area of a sphere with radius r, and a cone with<br>circular base with radius r and height h. Place them into a class “Geometry2.java

Extracted text: Exercise 3: A. Write static methods: • public static double sphereVolume(double r) :r3 • public static double sphereSurface(double r) : 47tr? • public static double coneVolume(double r, double h): – thr² public static double coneSurface(double r, double h) :7r(h +r) that compute the volume and surface area of a sphere with radius r, and a cone with circular base with radius r and height h. Place them into a class “Geometry2.java". Then write a program with main class called “Lab7_yourlD.java" that prompts the user for the values of r and h, calls the four methods, and prints the results.

Jun 06, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here