Easy Java Solution in Simple Math Formula
IntuitionApproachComplexity

Time complexity:  O(dimensions.length)


Space complexity: O(1)

Code
# Intuition
<!-- Describe your first thoughts on how to solve this problem. -->

# Approach
<!-- Describe your approach to solving the problem. -->

# Complexity
- Time complexity:  O(dimensions.length)

- Space complexity: O(1)

# Code
```java []
class Solution {
    public int areaOfMaxDiagonal(int[][] dimensions) {
        int area = 0;
        double maxi = 0;
        for(int[] num:dimensions)
        {
            int l = num[0];
            int b = num[1];
            double diagonal = Math.sqrt(num[0]*num[0] + num[1]*num[1]);
            if(diagonal >= maxi)
            {
                area =  maxi == diagonal ? Math.max(area, l*b) : l*b;
                maxi = diagonal;
            }
        }
        return area;
    }
}
```
['Array', 'Java']