Menu

Write Suitable C Function Satisfy Following 5 M Name Function Community Ii Called Return Q43783783

a) Write a suitable C function to satisfy the following: [5 m] i. The name of the function is community. ii. When it is callea) Write a suitable C function to satisfy the following: [5 m] i. The name of the function is community. ii. When it is called, it will return a floating point number. iii. The function would accept 3 integer numbers, num], num2, and num3. iv. The algorithm for the function is as below: 1. If num1 and num2 are equals, the function will return num3. 2. If num1 is greater than num2, the function will return num1 * num2 – num3. 3. If num1 is less than num2, and num3 is not equal to zero, the function will return floating point value of (numl + num2) / num3, otherwise it will print “sorry, division by zero” and return 0.0 Show transcribed image text a) Write a suitable C function to satisfy the following: [5 m] i. The name of the function is community. ii. When it is called, it will return a floating point number. iii. The function would accept 3 integer numbers, num], num2, and num3. iv. The algorithm for the function is as below: 1. If num1 and num2 are equals, the function will return num3. 2. If num1 is greater than num2, the function will return num1 * num2 – num3. 3. If num1 is less than num2, and num3 is not equal to zero, the function will return floating point value of (numl + num2) / num3, otherwise it will print “sorry, division by zero” and return 0.0

Expert Answer


Answer to a) Write a suitable C function to satisfy the following: [5 m] i. The name of the function is community. ii. When it is …

OR