Looks like your answer was very well covered by the other responders. Mine is just a nit since I think I know what you meant; but you said in your post:
"It should be 21 instead of 20 because..."
Did you mean "...11 instead of 10..." since you initialize your variable to 10 rather than to 20?
In reply to Re: Prefix and postfix increment/decrement operator query
by ack
in thread Prefix and postfix increment/decrement operator query
by saurabh.hirani
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |