There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
SCJA 1.0 (98%), SCJP 1.4 (98%)
"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer
sscce.org
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
SCJP 1.4, SCBCD 1.3
Thanks and Regards, Amit Taneja
Originally posted by amit taneja:
... but in x=x+++++y;
in this case it gets increment operator (++y)
so it puts like x = (x++) + (++y);
...
"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer
sscce.org
Originally posted by marc weber:
I don't think so. Compare the results of trying to compile the following different cases:
x = x+++++y;
x = ((x++)++)+y;
x = (x++)+(++y);
And consider the significance of unary operator precedence over binary operators (e.g., ++ over +).
[ June 02, 2005: Message edited by: marc weber ]
Thanks and Regards, Amit Taneja
Thanks and Regards, Amit Taneja
Originally posted by amit taneja:
...
x = x+++++y;
x = ((x++)++)+y; //this is right or
x = (x++)+(++y); // this is right
...
"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer
sscce.org
Your mother was a hamster and your father was a tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
|