662 views
0 votes
0 votes

#include <stdio.h>
int main(void)
{
    int a=3,b,c,d=10,e=20,f;

    c= ++a + a++ + a++ + ++a;


    b= ++d + ++d + ++d + ++d;


    f= ++e + --e + e-- + e++;

    printf("%d %d\n",a,c);

    printf("%d %d\n",d,b);

    printf("%d %d\n",e,f);

 return 0;
}

please give the detailed explanation how it works? and what is the output?

Please log in or register to answer this question.

Related questions

0 votes
0 votes
0 answers
2
Kaushal Sanadhya asked Oct 4, 2018
491 views
#include <stdio.h>int main(){ int i = 3; printf("%d", (++i)++); return 0;}Why does the above code is giving error?
0 votes
0 votes
1 answer
3
sumit_kumar asked May 1, 2018
2,435 views
Main (){Int x,y , z;X=y=z=1;Z=++x||++y&&++z;Printf ("x=%d y=%d z=%d",x,y,z);}
0 votes
0 votes
2 answers
4
Lakshman Bhaiya asked Apr 21, 2018
2,575 views
Q) What is the output of the following C Program fragment#include<stdio.h>int main(){int a = 4, b = 3;printf("%d",a+++++b);return 0;} A) 7 B) 8 C) 9 ...