Computer Science, asked by leelavatidevadiga456, 8 months ago

What is the error in the following program?
#include
int f(int a)
{
a>20?return (10):return (20);
}
int main()
{
int b;
b=f(20);
printf("%d\n".b);
return 0;
}
a)error:' return' statement cannot be used with conditional operators
b)error: prototype declaration
c)error: two return statements cannot be used in any function
d)no error

Answers

Answered by nehadagar679
2

Answer:

The error of this problem is (b)

because not mention when return case

so may be the answer is this

I am not sure

Explanation:

I hope the answer help you.

Mark as brainlist nd follow me ☺️....

Similar questions