please help me with this..... a=1; b = a++ + ++a+ ++a; the output is coming b=7... can any1 plzz explain
This is undefined behavior. Read Stroustrup's answer to the a++ + ++a FAQ http://www2.research.att.com/~bs/bs_faq2.html#evaluation-order