Ask your own question, for FREE!
Computer Science 20 Online
OpenStudy (yrelhan4):

#include int main(){ int a=2; a=a++ + ~++a; printf("%d",a); return 0; } The output to this prog is 0. Can anyone explain to me how the prog flows? The first think that will happen is the preincremnt term is solved.. a++ + ~3.. What happens next?

OpenStudy (yrelhan4):

@Callisto

OpenStudy (yrelhan4):

@DLS

OpenStudy (yrelhan4):

@DLS

OpenStudy (dls):

o teri,merko to ek bhi notification nahi ayi

OpenStudy (yrelhan4):

use chod. answer bta.. JALDI

OpenStudy (dls):

#include<stdio.h> int main(){ int a=2; a=a++ + ~++a; printf("%d",a); return 0; } The output to this prog is 0. Can anyone explain to me how the prog flows? The first think that will happen is the preincremnt term is solved.. a++ + ~3.. What happens next? ------------------------------ a=2 hai a++ + ++a hota to.. 2 + 4 = 6 hota ab bitwise compliment tu dekhle.

OpenStudy (dls):

a ko sahi evaluate kiya hai na tune?

OpenStudy (yrelhan4):

haan. ~3=-4 abhi prog bnake dekha maine. chad. dekhi jayegi. :/

OpenStudy (yrelhan4):

ho gya. kal btata hun.

OpenStudy (dls):

okay,badiya

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!