Ask Question
6 September, 06:48

Assign max_sum with the greater of num_a and num_b, PLUS the greater of num_y and num_z. Use just one statement. Hint: Call find_max () twice in an expression. Sample output with inputs: 5.0 10.0 3.0 7.0 max_sum is: 17.0

+3
Answers (1)
  1. 6 September, 08:16
    0
    def find_max (num_1, num_2):

    max_val = 0.0

    if (num_1 > num_2):

    max_val = num_1

    else:

    max_val = num_2

    return max_val

    max_sum = 0.0

    num_a = float (input ())

    num_b = float (input ())

    num_y = float (input ())

    num_z = float (input ())

    max_sum = find_max (num_a, num_b) + find_max (num_y, num_z)

    print ('max_sum is:', max_sum)
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “Assign max_sum with the greater of num_a and num_b, PLUS the greater of num_y and num_z. Use just one statement. Hint: Call find_max () ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers