subject
Engineering, 24.03.2020 04:53 sakinahunt

Assign to maxSum the max of (numA, numB) PLUS the max of (numY, numZ). Use just one statement. Hint: Call FindMax() twice in an expression.

#include

double FindMax(double num1, double num2) {

double maxVal = 0.0;

// Note: if-else statements need not be understood to complete this activity

if (num1 > num2) { // if num1 is greater than num2,

maxVal = num1; // then num1 is the maxVal.

}

else { // Otherwise,

maxVal = num2; // num2 is the maxVal.

}

return maxVal;

}

int main(void) {

double numA = 5.0;

double numB = 10.0;

double numY = 3.0;

double numZ = 7.0;

double maxSum = 0.0;

/* Your solution goes here */

printf("maxSum is: %.2f\n", maxSum);

return 0;

}

ansver
Answers: 2

Another question on Engineering

question
Engineering, 04.07.2019 18:10
The mass flow rate of the fluid remains constant in all steady flow process. a)- true b)- false
Answers: 1
question
Engineering, 04.07.2019 18:10
Which of the following ziegler nichols tuning methods the response of the controller to a step input should exhibit an s-shaped curve? a)-open loop mode b)-closed loop mode c)-both modes (open & closed) d)-none of the modes (open & closed)
Answers: 3
question
Engineering, 04.07.2019 18:10
True or false (explain) (110)[111] is a slip system in bcc metals . the {111} family in fcc contains 8 planes. resolved shear stress (rss) in single crystals is just related to the applied stress. critical resolved shear stress (crss) in single crystal metals is direct proportional to the number of defects in the structure
Answers: 2
question
Engineering, 04.07.2019 18:20
Acertain flow of air (at stp) has a velocity distribution given by v i (in ft/s). if this flow is going through a 4 ft square area in the yz-plane (centered at the origin), what is the mass flow rate (in lbm/s)?
Answers: 2
You know the right answer?
Assign to maxSum the max of (numA, numB) PLUS the max of (numY, numZ). Use just one statement. Hint:...
Questions
question
Mathematics, 08.02.2021 19:40
question
Mathematics, 08.02.2021 19:40
question
Mathematics, 08.02.2021 19:40