Straightforward + Clean & Easy Python with Comments!
\nclass Solution:\n    def diagonalSum(self, mat: List[List[int]]) -> int:\n        \n        total = 0\n        n = len(mat[0])-1\n        \n        for i in r
```\nclass Solution:\n    def diagonalSum(self, mat: List[List[int]]) -> int:\n        \n        total = 0\n        n = len(mat[0])-1\n        \n        for i in range(len(mat)):\n\t\t    # Add primary diagonal.\n            total += mat[i][i]\n\t\t\t# Add the secondary but avoid the middle point that overlaps the primary.\n            if i != n-i:\n                total += mat[i][n-i]\n            \n        return total\n```
['Python', 'Python3']