is there any difference between

a[i][j]+=MAX(a[i][j-1],a[i-1][j]);

and a[i][j]=a[i][j]+MAX(a[i][j-1],a[i-1][j]);

in the problem ‘magic rankings’ if i use the latter one, my solution doesnt work.

my solution to the problem is in the following link

http://www.codechef.com/viewsolution/1675348

a=a+b and a+=b should not be any different. i have no idea why it is different in this case. Please tell me why… thanks in advance