You are viewing a single comment's thread. Return to all comments →
def diagonalDifference(arr,n): left,right,i=0,0,0 while i != n: left+=arr[i][i] right+=arr[i][n-1-i] i+=1 return abs(left-right)
Diagonal Difference
You are viewing a single comment's thread. Return to all comments →