🐌 C# - straightforward and LINQ
\npublic class Solution\n{\n    public int MaxArea(int h, int w, int[] horizontalCuts, int[] verticalCuts)\n    {\n        long maxWidth = GetMax(h, horizontalC
```\npublic class Solution\n{\n    public int MaxArea(int h, int w, int[] horizontalCuts, int[] verticalCuts)\n    {\n        long maxWidth = GetMax(h, horizontalCuts);\n        long maxHeight = GetMax(w, verticalCuts);\n        return (int) (maxWidth * maxHeight % 1000000007);\n\n        static long GetMax(int length, int[] cuts)\n        {\n            Array.Sort(cuts);\n            int max = Math.Max(cuts[0], length - cuts[^1]);\n            for (int index = 1; index < cuts.Length; index++)\n            {\n                max = Math.Max(cuts[index] - cuts[index - 1], max);\n            }\n\n            return max;\n        }\n    }\n}\n```\n\nLINQ\n```\npublic class Solution\n{\n    public int MaxArea(int h, int w, int[] horizontalCuts, int[] verticalCuts)\n    {\n        long maxWidth = GetMax(h, horizontalCuts);\n        long maxHeight = GetMax(w, verticalCuts);\n        return (int) (maxWidth * maxHeight % 1000000007);\n\n        long GetMax(int length, int[] cuts) => cuts\n            .OrderBy(cut => cut)\n            .Append(length)\n            .Aggregate((Previous: 0, Max: 0), (x, current) => (current, Math.Max(x.Max, current - x.Previous)))\n            .Max;\n    }\n}\n```
['C#']