main()
{
int i = -3,j=2,k=0,m;
m= ++i || ++j && ++k;
printf("%d%d%d",i,j,k,m);
}
Answer Posted / harend
results :
i=-2
j=2
k=0
m=1
First, the '&&' part is to be considered over '||'.
AS follow: m = ++i||++j&&++k (is given)
what ever be the result of (++j&&++k),the value of m =1
,since the new value i= -2 (i.e a non zero value so taken as
true or 1)
so,
1||(++j&&++k) will always be true, that is 1 . compiler
ignores ++j ,++k and only consider ++i.
thank you !
| Is This Answer Correct ? | 25 Yes | 6 No |
Post New Answer View All Answers
how to create duplicate link list using C???
write a sorting prgm to sort 50 nos and sum them and also remove all the occurrences of 15 and print it?
Is c a great language, or what?
Differentiate call by value and call by reference?
What does 3 mean in texting?
What is console in c language?
What is wrong in this statement?
What is volatile c?
What are the different types of control structures in programming?
What is the purpose of main() function?
What does a pointer variable always consist of?
The file stdio.h, what does it contain?
Can you pass an entire structure to functions?
What is getch c?
what are the 10 different models of writing an addition program in C language?