Beats 100% runtime!!
IntuitionIf both sides of one rectangle are greater than both sides of another rectangle, then the first rectangle definitely has the longer diagonal since we h
# Intuition
If both sides of one rectangle are **greater** than both sides of another rectangle, then the first rectangle definitely has the longer diagonal since we have to sum the square of both sides to find the diagonal. Note: we do not need to find the square root as the square root of a larger number is **always** greater than  the square root of a smaller number.

Next, say the width of rectangle 1 is greater than  that of rectangle 2, the diagonal of rectangle 2 can stil be greater than that of rectangle 1 **IF AND ONLY** if the length of rectangle 2 is greater than that of rectangle 1.

Finally, two rectangles having the same diagonal length doesnt always mean they have the same area. 

# Approach
<!-- Describe your approach to solving the problem. -->
First we get the dimensions for the first rectangle and set that to our maximum length and maximum width. Then we compute the diagonal for that without finding the square root.

And then we iterate through the rest of the list. We only need to stop for any rectangle where one of the sides is **equal or greater** than the corresponding side for the current max rectangle. This is because if one side is greater or equal to, theres a chance the diagonal is greater than the maxDiagonal.

When we find such rectangle, we wanna check if its **diagonal** is **greater** than the maxDiagonal so far. If it is, we update the maxLength, maxWidth and maxDiagonal.

If its diagonal is however **equal** to the max diagonal, we are then going to check if its **area** is **greater**. If it is, we update the maxLength, maxWidth and maxDiagonal.

# Complexity
- Time complexity:
<$$O(n)$$ -->



# Code
```python3 []
class Solution:
    def areaOfMaxDiagonal(self, dimensions: List[List[int]]) -> int:
        maxLength, maxWidth = (dimensions[0][0], dimensions[0][1])
        maxDiagonal = maxLength*maxLength + maxWidth*maxWidth

        for i in range(1, len(dimensions)):
            length = dimensions[i][0]
            width = dimensions[i][1]
            diagonal = length*length + width*width

            if length >= maxLength or width >= maxWidth:

                if diagonal > maxDiagonal:
                    maxLength, maxWidth = (length, width)
                    maxDiagonal = diagonal

                elif diagonal == maxDiagonal:
                    area = length * width
                    if area > maxLength * maxWidth:
                        maxLength, maxWidth = (length, width)
        return maxLength * maxWidth


                
```
['Python3']