Assume the following function is defined: /function that returns the larger of two integers * int max(int numl, int num2
-
answerhappygod
- Site Admin
- Posts: 899604
- Joined: Mon Aug 02, 2021 8:13 am
Assume the following function is defined: /function that returns the larger of two integers * int max(int numl, int num2
Assume the following function is defined: /function that returns the larger of two integers * int max(int numl, int num2) int result: if (num > num2) result = num; else result - num2; return results What will be displayed for the value of answer if the following statements are executed in main? int a printf("Enter the value for a: \n"); scanf("d", ta): Int b-a + 1; int answer - max( ab); printf("The answer is: $d\n", answer): a. It depends on what the user enters for a b. Always the value of num1. O c A value of O, indicating that max ended normally d. Always the value of num2
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!