B
BIGeasy
I'm trying to create an program that:
1. Prompts the user to enter three numbers and show the largest of the
three.
2.Takes the largest number and raises it to the smallest number.
3.Takes that result and raises it to the middle number.
I'm have step1 and 2 down, but I'm having trouble with the third
function which is step3. Here is the code I have for the function so
far:
//Raises the result of powerhouse1 to the middle
double powerhouse2(double mth, double nth, double oth)
{
double lowrise = pow(mth, oth);
double higherrise = pow(lowrise, nth);
return higherrise;
}
1. Prompts the user to enter three numbers and show the largest of the
three.
2.Takes the largest number and raises it to the smallest number.
3.Takes that result and raises it to the middle number.
I'm have step1 and 2 down, but I'm having trouble with the third
function which is step3. Here is the code I have for the function so
far:
//Raises the result of powerhouse1 to the middle
double powerhouse2(double mth, double nth, double oth)
{
double lowrise = pow(mth, oth);
double higherrise = pow(lowrise, nth);
return higherrise;
}