1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
uysha [10]
4 years ago
12

Define a method pyramidVolume with double parameters baseLength, baseWidth, and pyramidHeight, that returns as a double the volu

me 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)

import java.util.Scanner;

public class CalcPyramidVolume {

/* Your solution goes here */

public static void main (String [] args) {
System.out.println("Volume for 1.0, 1.0, 1.0 is: " + pyramidVolume(1.0, 1.0, 1.0));
return;
Physics
2 answers:
Maksim231197 [3]4 years ago
8 0

Answer:  Volume = 8/3

Explanation:

Let x represent the base length, base width and height  

Volume = 2x X 2x X 2x X 1/3 = 8x³/3

When x = 1.0

∴ Volume = 8(1.0)³/3 = 8/3

lara31 [8.8K]4 years ago
3 0

Answer:

Explanation:

Its not a good practice to write all the functions including main() in the same class.

But as you opted for this, the code goes here like this:

public class CalcPyramidVolume {

/* Your solution goes here */

static double pyramidVolume(double baseLength, double baseWidth, double pyramidHeight)

{

double Volume,baseArea;

baseArea = baseLength * baseWidth;

Volume = baseArea * pyramidHeight * 1/3;

return Volume;

}

public static void main (String [] args) {

System.out.println("Volume for 1.0, 1.0, 1.0 is: " + pyramidVolume(1.0, 1.0, 1.0));

return;

}

}

And there is not caveat of integer division, as you are declaring all your variables of type double.

You might be interested in
What would happen to plasma membrane if proteins were absent
Inessa [10]

Cell membranes are 50% protein, the proteins are responsible for many biological processes. If the proteins were absent the membrane could not carry out it's intended purpose.

8 0
4 years ago
How does the thickness of a planets atmosphere affect a planets average temperature
scZoUnD [109]

Answer:

Hey

The thickness of a planet's atmosphere determines the tempature. the reason why is because gas traps or reflects light. Gass molecules generally reflect light which means that photons bounce of gass molecules. But the space between these molecules allows most of the light to travel through and hit the   planet.

4 0
3 years ago
If you graph the average velocity (y-axis) vs. the elapsed time (x-axis), what
Aleks [24]

Answer:

a diagonal line on the graph

Explanation:

the slope would be constant at an increasing rate

y=x

uniform= increasing at a constant rate

4 0
4 years ago
what kinds of change in the extemal environment might a cell respond to (i also didbt see plain science so
Maru [420]

Answer:

The environments in which cells grow often change rapidly.

Explanation:

4 0
3 years ago
True or False: Our food has potential energy?
DanielleElmas [232]

Hello User,

Answer is yes.

Explanation

<em>At the most fundamental level, chemical energy is stored in food as molecular bonds. These molecular bonds represent potential energy, which is either very stable, such as in fat molecules, or very active and transitory, such as in ATP molecules.</em>

Hope it helps you... pls mark brainliest

3 0
3 years ago
Read 2 more answers
Other questions:
  • n general, which trophic level has the LEAST energy available to it? A) producer B) primary consumer C) secondary consumer D) te
    9·1 answer
  • A small bouncy ball with a momentum of 8 kg∙m/s to the left approaches head-on a large door at rest. The ball bounces straight b
    14·1 answer
  • What do we call the certain electrons that are able to sometimes wander<br> away or be shared? *
    12·1 answer
  • 4 The time to failure of an electrical component has a Weibull distribution with parameters λ = 0.056 and a = 2.5. A random coll
    6·1 answer
  • PLEAE ASAP
    7·1 answer
  • A mule pulls a cart of milk 10 meters with a force of 50 Newton's.Calculate the work done by a mule
    5·2 answers
  • which two objects have stored energy A)a ball rolling on the ground B) a small rock sitting on top of a big rock C)a stretched r
    14·2 answers
  • Unos amigos de 5 integrantes salen a comer, el primero pide un pollo a la brasa que cuesta S/50.00, el segundo un aeropuerto que
    5·1 answer
  • Hey I need help can someone help me out, please
    12·1 answer
  • Three metal fishing weights, each with a mass of 1.00x102 g and at a temperature of 100.0°C, are placed in 1.00x102 g of water a
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!