BEATS 100% || EASY || DETAILED.
\n\n# Code\n\nclass Solution {\n    public int areaOfMaxDiagonal(int[][] dimensions) {\n        double maxDiagonal = 0;\n        int maxArea = 0;\n        for (
\n\n# Code\n```\nclass Solution {\n    public int areaOfMaxDiagonal(int[][] dimensions) {\n        double maxDiagonal = 0;\n        int maxArea = 0;\n        for (int i = 0; i < dimensions.length; i++) {\n            double length = dimensions[i][0];\n            double width = dimensions[i][1];\n            double diagonal = Math.sqrt(length * length + width * width);\n            int area = (int) (length * width);\n            if (diagonal > maxDiagonal || (diagonal == maxDiagonal && area > maxArea)) {\n                maxDiagonal = diagonal;\n                maxArea = area;\n            }\n        }\n        return maxArea;\n    }\n}\n\n```
['Array', 'C++', 'Java']