toThePowerOf is a method that accepts two int arguments and returns the value of the first parameter raised to the power of the second.

LANGUAGE: JAVA

CHALLENGE:

toThePowerOf is a method that accepts two int arguments and returns the value of the first parameter raised to the power of the second.

An int variable cubeSide has already been declared and initialized . Another int variable , cubeVolume, has already been declared .

Write a statement that calls toThePowerOf to compute the value of cubeSide raised to the power of 3 and that stores this value in cubeVolume.

Assume that toThePowerOf is defined in the same class that calls it.

SOLUTION:

The Bad News: The content you are trying to access is only available to members.

The Good News: You too can be a member, simply Click Here.

Already a member?

Posted in ,