Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

3.5.3 Method definition: Volume of a pyramid ACTIVITY Define a method pyramidVolume with double parameters baselength, baseWidth, and pyramidHeight, that returns as a double the

image text in transcribed

3.5.3 Method definition: Volume of a pyramid ACTIVITY Define a method pyramidVolume with double parameters baselength, baseWidth, and pyramidHeight, that returns as a double the volume of a pyramid with a rectangular base. Relevant geometry equations Volume base area x height x 1/3 Base area base length x base width (Watch out for integer division) 1 import java. util. Scanner; 1 test public class CalcPyramidVolume f 4 double pyramidvolume (double baselength, double basewidth, double pyramidHeight) public static void pyramidVolume ((baseLength . basewidth) . pyramidHeight) / 3; All tests passed 7 8 Your solution goes here 1e public static void main (String [] args) CalcPyramidvolume volumeCalculator new CalcPyramidVolume(); System.out.printin("Volume for 1.e, 1.8, 1.8 is: "volumeCalculator.pyramidvolume(1.e, 1.e, 1.e)); 12 13 14 Run Failed to compile CalcPyramidVol ume.java:7 error: illegal start of expression public static void pyramidVolume = ((baseLength * basewidth) * pyrami dHeight) / 3; CalcPyramidvolume.java:7: error: ' expected public static void pyramidVolume ((baseLength baseWidth) pyramidHeight) 3: O Type here to search 915 PM 9/23/20

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data Management Databases And Organizations

Authors: Richard T. Watson

3rd Edition

0471418455, 978-0471418450

More Books

Students also viewed these Databases questions

Question

What is conservative approach ?

Answered: 1 week ago

Question

What are the basic financial decisions ?

Answered: 1 week ago

Question

What are Decision Trees?

Answered: 1 week ago

Question

What is meant by the Term Glass Ceiling?

Answered: 1 week ago