0
When the shorthand method is not to be used for assignment operators in C/C++?
As there are two syntax for same instruction there must be drawback to any one of them. Can anybody explain that?
5 Answers
+ 5
Which language and which "instructions" you are talking about?
+ 1
It is still unclear. Can you please say what are the 2 syntaxes you are referring to?
+ 1
x += (some + very(long)) / expression
is easier to read and understand than
x = x + (some + very(long)) / expression
It might also be more efficient on some compilers.
But mostly it is for looks. "x =" means "replace x" and "x +=" means "modify x".
0
I have updated the question.
https://www.sololearn.com/discuss/1836414/?ref=app
0
x+=4;
x=x+4;
The two syntax above are performing same instruction. So what is the merits and drawback of using an alternate method(x+=4)?