I've always found that the +=
operator only worked as a shorter form for the traditional increment, for example:
i += j;
Instead of:
i = i + j;
But when performing the following experiment:
int i = 3;
long j = 7;
So when I run i = i + j;
it results in error, while i += j;
compiles normally.
Given this, is it possible to state that i += j;
is actually similar to i = (tipo do i) (i + j);
?