what does the following function print?
func(int i)
{
if(i%2)return 0;
eale return 1;
}
main()
{
int =3;
i=func(i);
i=func(i);
printf("%d",i);}
Answers were Sorted based on User's Feedback
Answer / manju
The code returns error as i is undeclared see in main int
=3 and instead of else eale is used.
| Is This Answer Correct ? | 13 Yes | 1 No |
Answer / shrinidhi
in the question in 'func' function there is a word 'eale'.
what u mean by that? if it is 'else' then the ans is "1".
| Is This Answer Correct ? | 4 Yes | 2 No |
Answer / mahi
The code returns error as i is undeclared see in main
int =3 and
instead of
else eale is used.
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / anilkumar927@gmail.com
It gives errors and warring……….. those are as follows:
1) i is not declared in main function
2) Return type of func is not mentioned
3) eale is wrong in the func function
if every thing is correct in the QNS then
i hope that the ans is "zero"
| Is This Answer Correct ? | 4 Yes | 4 No |
How is a structure member accessed?
What is the use of function overloading in C?
Differentiate between a structure and a union.
What is difference between the following 2 lines…. int temp = (int)(0x00); int temp = (0x00int);
console I/O functions means a) the I/O operations done on disk b) the I/O operations done in all parts c) the input given through keyboard is displayed VDU screen d) none of the above
I came across some code that puts a (void) cast before each call to printf. Why?
What is fflush() function?
Will Macros support multiple arguments ?
Write a program to display all the prime nos from 1 to 1000000, your code should not take time more than a minute to display all the nos.
program for following output using for loop? 1 2 3 4 5 2 3 4 5 3 4 5 4 5 5
Differentiate between the expression “++a” and “a++”?
What is an example of enumeration?